Backend (app/imitate.py):
- GET /api/imitate/products — reads imitate: config, checks online status
- GET /api/imitate/products/{id}/sample — fetches real item from product API
- GET /api/imitate/run (SSE) — streams ollama responses for selected models
- POST /api/imitate/push-corrections — queues results in SFT corrections JSONL
Frontend (ImitateView.vue):
- Step 1: product picker grid (online/offline status, icon from config)
- Step 2: raw sample preview + editable prompt textarea
- Step 3: ollama model multi-select, temperature slider, SSE run with live log
- Step 4: response cards side by side, push to Corrections button
Wiring:
- app/api.py: include imitate_router at /api/imitate
- web/src/router: /imitate route + lazy import
- AppSidebar: Imitate nav entry (mirror icon)
- config/label_tool.yaml.example: imitate: section with peregrine example
- 16 unit tests (100% passing)
Also: BenchmarkView.vue Compare panel — side-by-side run diff for bench results
91 lines
3.3 KiB
Text
91 lines
3.3 KiB
Text
# config/label_tool.yaml — Multi-account IMAP config for the email label tool
|
|
# Copy to config/label_tool.yaml and fill in your credentials.
|
|
# This file is gitignored.
|
|
|
|
accounts:
|
|
- name: "Gmail"
|
|
host: "imap.gmail.com"
|
|
port: 993
|
|
username: "you@gmail.com"
|
|
password: "your-app-password" # Use an App Password, not your login password
|
|
folder: "INBOX"
|
|
days_back: 90
|
|
|
|
- name: "Outlook"
|
|
host: "outlook.office365.com"
|
|
port: 993
|
|
username: "you@outlook.com"
|
|
password: "your-app-password"
|
|
folder: "INBOX"
|
|
days_back: 90
|
|
|
|
# Optional: limit emails fetched per account per run (0 = unlimited)
|
|
max_per_account: 500
|
|
|
|
# cf-orch SFT candidate import — path to the bench_results/ directory
|
|
# produced by circuitforge-orch's benchmark harness.
|
|
sft:
|
|
bench_results_dir: /path/to/circuitforge-orch/scripts/bench_results
|
|
|
|
# cf-orch integration — LLM benchmark harness via cf-orch coordinator.
|
|
# All keys here override the corresponding environment variables.
|
|
# Omit any key to fall back to the env var (see .env.example).
|
|
cforch:
|
|
# Path to cf-orch's benchmark.py script
|
|
bench_script: /path/to/circuitforge-orch/scripts/benchmark.py
|
|
# Task and model definition files (yaml)
|
|
bench_tasks: /path/to/circuitforge-orch/scripts/bench_tasks.yaml
|
|
bench_models: /path/to/circuitforge-orch/scripts/bench_models.yaml
|
|
# Where benchmark results are written (also used for SFT candidate discovery)
|
|
results_dir: /path/to/circuitforge-orch/scripts/bench_results
|
|
# Python interpreter with cf-orch installed
|
|
python_bin: /devl/miniconda3/envs/cf/bin/python
|
|
|
|
# Connection config — override env vars CF_ORCH_URL / CF_LICENSE_KEY / OLLAMA_HOST
|
|
# coordinator_url: http://localhost:7700
|
|
# license_key: CFG-AVCT-xxxx-xxxx-xxxx
|
|
# ollama_url: http://localhost:11434
|
|
# ollama_model: llama3.2:3b
|
|
|
|
# Imitate tab — pull real samples from sibling CF product APIs and run them
|
|
# through local LLMs to build a corrections dataset.
|
|
# ollama_url defaults to cforch.ollama_url if omitted here.
|
|
imitate:
|
|
ollama_url: http://localhost:11434 # optional — falls back to cforch.ollama_url
|
|
|
|
products:
|
|
- id: peregrine
|
|
name: Peregrine
|
|
icon: "🦅"
|
|
description: Job search assistant
|
|
base_url: http://localhost:8502
|
|
sample_endpoint: /api/jobs
|
|
text_fields: [title, description]
|
|
prompt_template: "Analyze this job listing and identify key requirements:\n\n{text}"
|
|
|
|
- id: kiwi
|
|
name: Kiwi
|
|
icon: "🥝"
|
|
description: Pantry tracker
|
|
base_url: http://localhost:8511
|
|
sample_endpoint: /api/inventory
|
|
text_fields: [name, category, notes]
|
|
prompt_template: "Describe this pantry item and estimate how best to use it:\n\n{text}"
|
|
|
|
- id: snipe
|
|
name: Snipe
|
|
icon: "🎯"
|
|
description: eBay trust scoring
|
|
base_url: http://localhost:8509
|
|
sample_endpoint: /api/listings
|
|
text_fields: [title, description, seller_info]
|
|
prompt_template: "Evaluate the trustworthiness of this listing and flag any red flags:\n\n{text}"
|
|
|
|
- id: osprey
|
|
name: Osprey
|
|
icon: "📞"
|
|
description: Gov't hold-line automation
|
|
base_url: http://localhost:8520
|
|
sample_endpoint: /api/calls/recent
|
|
text_fields: [agency, issue, notes]
|
|
prompt_template: "Draft a concise summary of this government call record:\n\n{text}"
|