Complete remaining medium/low issues: performance, CLI, types, CI, tests
Performance: - Batch readiness computation (~200 queries → ~6 per page) - Batch draft lookup in author network (N+1 → single query) - File-based similarity matrix cache (.npy + metadata sidecar) - 5-minute TTL embedding cache for search queries CLI quality: - Add pass_cfg_db decorator, convert ~30 commands to shared config/db lifecycle - Add --dry-run to analyze, embed, embed-ideas, ideas, gaps commands - Move 15+ in-function imports to top of data.py Types & documentation: - Add 16 TypedDicts to data.py, annotate 12 function return types - Add ethics section to Post 06 (premature standardization, power asymmetry) - Add EU AI Act Article 43 conformity mapping to Post 06 - Add NIS2 and CRA references to Post 04 CI & testing: - Add GitHub Actions CI workflow (Python 3.11+3.12, ruff, pytest) - Add API documentation for all 20 endpoints (data/reports/api-docs.md) - Add 41 new tests (test_analyzer.py, test_search.py) — 64 total pass Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -13,16 +13,15 @@ CONFIG_FILE = DEFAULT_DATA_DIR / "config.json"
|
||||
DEFAULT_KEYWORDS = [
|
||||
"agent",
|
||||
"ai-agent",
|
||||
"llm",
|
||||
"autonomous",
|
||||
"machine-learning",
|
||||
"artificial-intelligence",
|
||||
"mcp",
|
||||
"agentic",
|
||||
"autonomous",
|
||||
"mcp",
|
||||
"inference",
|
||||
"generative",
|
||||
"intelligent",
|
||||
"aipref",
|
||||
"large language model",
|
||||
"multi-agent",
|
||||
"trustworth",
|
||||
]
|
||||
|
||||
# Environment variable overrides (env var name -> config field name)
|
||||
@@ -39,6 +38,7 @@ class Config:
|
||||
db_path: str = str(DEFAULT_DATA_DIR / "drafts.db")
|
||||
ollama_url: str = "http://localhost:11434"
|
||||
ollama_embed_model: str = "nomic-embed-text"
|
||||
ollama_classify_model: str = "llama3.2"
|
||||
claude_model: str = "claude-sonnet-4-20250514"
|
||||
claude_model_cheap: str = "claude-haiku-4-5-20251001"
|
||||
search_keywords: list[str] = field(default_factory=lambda: list(DEFAULT_KEYWORDS))
|
||||
|
||||
Reference in New Issue
Block a user