genoma-evolution 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.brv/.obsidian/app.json +1 -0
- package/.brv/.obsidian/appearance.json +1 -0
- package/.brv/.obsidian/core-plugins.json +33 -0
- package/.brv/.obsidian/graph.json +22 -0
- package/.brv/.obsidian/workspace.json +195 -0
- package/.brv/Sin ti/314/201tulo 1.canvas" +1 -0
- package/.brv/Sin ti/314/201tulo 2.canvas" +1 -0
- package/.brv/Sin ti/314/201tulo.canvas" +1 -0
- package/.brv/_queue_status.json +1 -0
- package/.brv/config.json +5 -0
- package/.brv/context-tree/_index.md +60 -0
- package/.brv/context-tree/_manifest.json +165 -0
- package/.brv/context-tree/backend/_index.md +24 -0
- package/.brv/context-tree/backend/backend/_index.md +40 -0
- package/.brv/context-tree/backend/backend/init.abstract.md +0 -0
- package/.brv/context-tree/backend/backend/init.md +27 -0
- package/.brv/context-tree/backend/backend/init.overview.md +29 -0
- package/.brv/context-tree/backend/backend/job_tracker.abstract.md +1 -0
- package/.brv/context-tree/backend/backend/job_tracker.md +273 -0
- package/.brv/context-tree/backend/backend/job_tracker.overview.md +31 -0
- package/.brv/context-tree/backend/backend/main.abstract.md +0 -0
- package/.brv/context-tree/backend/backend/main.md +1292 -0
- package/.brv/context-tree/backend/backend/main.overview.md +30 -0
- package/.brv/context-tree/backend/backend/requirements.abstract.md +1 -0
- package/.brv/context-tree/backend/backend/requirements.md +37 -0
- package/.brv/context-tree/backend/backend/requirements.overview.md +28 -0
- package/.brv/context-tree/docs/_index.md +37 -0
- package/.brv/context-tree/docs/api/_index.md +54 -0
- package/.brv/context-tree/docs/api/context.md +11 -0
- package/.brv/context-tree/docs/api/hermes_api_openapi_specification.abstract.md +0 -0
- package/.brv/context-tree/docs/api/hermes_api_openapi_specification.md +468 -0
- package/.brv/context-tree/docs/api/hermes_api_openapi_specification.overview.md +44 -0
- package/.brv/context-tree/frontend/_index.md +48 -0
- package/.brv/context-tree/frontend/hermes_dashboard/_index.md +31 -0
- package/.brv/context-tree/frontend/hermes_dashboard/architecture_overview.abstract.md +0 -0
- package/.brv/context-tree/frontend/hermes_dashboard/architecture_overview.md +41 -0
- package/.brv/context-tree/frontend/hermes_dashboard/architecture_overview.overview.md +34 -0
- package/.brv/context-tree/frontend/src/_index.md +53 -0
- package/.brv/context-tree/frontend/src/components/_index.md +52 -0
- package/.brv/context-tree/frontend/src/components/sidebar_navigation_component.abstract.md +0 -0
- package/.brv/context-tree/frontend/src/components/sidebar_navigation_component.md +161 -0
- package/.brv/context-tree/frontend/src/components/sidebar_navigation_component.overview.md +32 -0
- package/.brv/context-tree/frontend/src/context.md +10 -0
- package/.brv/context-tree/frontend/src/functioncallingpage.abstract.md +0 -0
- package/.brv/context-tree/frontend/src/functioncallingpage.md +34 -0
- package/.brv/context-tree/frontend/src/functioncallingpage.overview.md +26 -0
- package/.brv/context-tree/frontend/src/lib/_index.md +48 -0
- package/.brv/context-tree/frontend/src/lib/api_client_library.abstract.md +1 -0
- package/.brv/context-tree/frontend/src/lib/api_client_library.md +403 -0
- package/.brv/context-tree/frontend/src/lib/api_client_library.overview.md +69 -0
- package/.brv/context-tree/frontend/src/page.abstract.md +0 -0
- package/.brv/context-tree/frontend/src/page.md +103 -0
- package/.brv/context-tree/frontend/src/page.overview.md +7 -0
- package/.brv/context-tree/frontend/src/settingspage.abstract.md +0 -0
- package/.brv/context-tree/frontend/src/settingspage.md +124 -0
- package/.brv/context-tree/frontend/src/settingspage.overview.md +34 -0
- package/.brv/context-tree/frontend/src/sidebar.abstract.md +0 -0
- package/.brv/context-tree/frontend/src/sidebar.md +170 -0
- package/.brv/context-tree/frontend/src/sidebar.overview.md +25 -0
- package/.brv/context-tree/meta/_index.md +24 -0
- package/.brv/context-tree/meta/curation_context/_index.md +24 -0
- package/.brv/context-tree/meta/curation_context/empty_context.abstract.md +4 -0
- package/.brv/context-tree/meta/curation_context/empty_context.md +35 -0
- package/.brv/context-tree/meta/curation_context/empty_context.overview.md +20 -0
- package/.brv/dream-log/drm-1777341062653.json +33 -0
- package/.brv/dream-state.json +8 -0
- package/.brv/dream.lock +0 -0
- package/.brv/review-backups/docs/api/hermes_api_openapi_specification.md +468 -0
- package/.claude/settings.local.json +7 -0
- package/.claude/worktrees/phase-2-mcp/.brv/.obsidian/app.json +1 -0
- package/.claude/worktrees/phase-2-mcp/.brv/.obsidian/appearance.json +1 -0
- package/.claude/worktrees/phase-2-mcp/.brv/.obsidian/core-plugins.json +33 -0
- package/.claude/worktrees/phase-2-mcp/.brv/.obsidian/graph.json +22 -0
- package/.claude/worktrees/phase-2-mcp/.brv/.obsidian/workspace.json +195 -0
- package/.claude/worktrees/phase-2-mcp/.brv/Sin t/303/255tulo 1.canvas" +1 -0
- package/.claude/worktrees/phase-2-mcp/.brv/Sin t/303/255tulo 2.canvas" +1 -0
- package/.claude/worktrees/phase-2-mcp/.brv/Sin t/303/255tulo.canvas" +1 -0
- package/.claude/worktrees/phase-2-mcp/.brv/_queue_status.json +1 -0
- package/.claude/worktrees/phase-2-mcp/.brv/config.json +5 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/_index.md +60 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/_manifest.json +165 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/backend/_index.md +24 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/backend/backend/_index.md +40 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/backend/backend/init.abstract.md +0 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/backend/backend/init.md +27 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/backend/backend/init.overview.md +29 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/backend/backend/job_tracker.abstract.md +1 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/backend/backend/job_tracker.md +273 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/backend/backend/job_tracker.overview.md +31 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/backend/backend/main.abstract.md +0 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/backend/backend/main.md +1292 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/backend/backend/main.overview.md +30 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/backend/backend/requirements.abstract.md +1 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/backend/backend/requirements.md +37 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/backend/backend/requirements.overview.md +28 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/docs/_index.md +37 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/docs/api/_index.md +54 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/docs/api/context.md +11 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/docs/api/hermes_api_openapi_specification.abstract.md +0 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/docs/api/hermes_api_openapi_specification.md +468 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/docs/api/hermes_api_openapi_specification.overview.md +44 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/_index.md +48 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/hermes_dashboard/_index.md +31 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/hermes_dashboard/architecture_overview.abstract.md +0 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/hermes_dashboard/architecture_overview.md +41 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/hermes_dashboard/architecture_overview.overview.md +34 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/src/_index.md +53 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/src/components/_index.md +52 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/src/components/sidebar_navigation_component.abstract.md +0 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/src/components/sidebar_navigation_component.md +161 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/src/components/sidebar_navigation_component.overview.md +32 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/src/context.md +10 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/src/functioncallingpage.abstract.md +0 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/src/functioncallingpage.md +34 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/src/functioncallingpage.overview.md +26 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/src/lib/_index.md +48 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/src/lib/api_client_library.abstract.md +1 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/src/lib/api_client_library.md +403 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/src/lib/api_client_library.overview.md +69 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/src/page.abstract.md +0 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/src/page.md +103 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/src/page.overview.md +7 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/src/settingspage.abstract.md +0 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/src/settingspage.md +124 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/src/settingspage.overview.md +34 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/src/sidebar.abstract.md +0 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/src/sidebar.md +170 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/frontend/src/sidebar.overview.md +25 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/meta/_index.md +24 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/meta/curation_context/_index.md +24 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/meta/curation_context/empty_context.abstract.md +4 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/meta/curation_context/empty_context.md +35 -0
- package/.claude/worktrees/phase-2-mcp/.brv/context-tree/meta/curation_context/empty_context.overview.md +20 -0
- package/.claude/worktrees/phase-2-mcp/.brv/dream-log/drm-1777341062653.json +33 -0
- package/.claude/worktrees/phase-2-mcp/.brv/dream-state.json +8 -0
- package/.claude/worktrees/phase-2-mcp/.brv/dream.lock +0 -0
- package/.claude/worktrees/phase-2-mcp/.brv/review-backups/docs/api/hermes_api_openapi_specification.md +468 -0
- package/.claude/worktrees/phase-2-mcp/.claude/settings.local.json +13 -0
- package/.claude/worktrees/phase-2-mcp/.kilocode/package-lock.json +378 -0
- package/.claude/worktrees/phase-2-mcp/.kilocode/package.json +5 -0
- package/.claude/worktrees/phase-2-mcp/AGENTS.md +5 -0
- package/.claude/worktrees/phase-2-mcp/CLAUDE.md +29 -0
- package/.claude/worktrees/phase-2-mcp/QA_AUDIT_PLAN.md +156 -0
- package/.claude/worktrees/phase-2-mcp/README.md +316 -0
- package/.claude/worktrees/phase-2-mcp/agent-agnostic-evolution-dashboard.md +405 -0
- package/.claude/worktrees/phase-2-mcp/backend/__init__.py +0 -0
- package/.claude/worktrees/phase-2-mcp/backend/collectors/__init__.py +0 -0
- package/.claude/worktrees/phase-2-mcp/backend/collectors/claude_code_collector.py +277 -0
- package/.claude/worktrees/phase-2-mcp/backend/collectors/hermes_collector.py +68 -0
- package/.claude/worktrees/phase-2-mcp/backend/curator.py +512 -0
- package/.claude/worktrees/phase-2-mcp/backend/eval/__init__.py +19 -0
- package/.claude/worktrees/phase-2-mcp/backend/eval/engine.py +116 -0
- package/.claude/worktrees/phase-2-mcp/backend/eval/scorers.py +201 -0
- package/.claude/worktrees/phase-2-mcp/backend/generate_dataset.py +86 -0
- package/.claude/worktrees/phase-2-mcp/backend/job_tracker.py +232 -0
- package/.claude/worktrees/phase-2-mcp/backend/main.py +1746 -0
- package/.claude/worktrees/phase-2-mcp/backend/mcp_server.py +250 -0
- package/.claude/worktrees/phase-2-mcp/backend/promethean/__init__.py +24 -0
- package/.claude/worktrees/phase-2-mcp/backend/promethean/cycle_orchestrator.py +270 -0
- package/.claude/worktrees/phase-2-mcp/backend/promethean/delta_validator.py +191 -0
- package/.claude/worktrees/phase-2-mcp/backend/promethean/dspy_compiler.py +315 -0
- package/.claude/worktrees/phase-2-mcp/backend/promethean/gepa_strategist.py +213 -0
- package/.claude/worktrees/phase-2-mcp/backend/promethean/models.py +260 -0
- package/.claude/worktrees/phase-2-mcp/backend/promethean/skill_deployer.py +195 -0
- package/.claude/worktrees/phase-2-mcp/backend/promethean/trace_ingestion.py +142 -0
- package/.claude/worktrees/phase-2-mcp/backend/requirements.txt +6 -0
- package/.claude/worktrees/phase-2-mcp/backend/sdd_evolve.py +459 -0
- package/.claude/worktrees/phase-2-mcp/backend/skill_detector.py +227 -0
- package/.claude/worktrees/phase-2-mcp/backend/skill_registry.py +289 -0
- package/.claude/worktrees/phase-2-mcp/backend/storage/__init__.py +5 -0
- package/.claude/worktrees/phase-2-mcp/backend/storage/run_store.py +393 -0
- package/.claude/worktrees/phase-2-mcp/backend/storage/schema.sql +99 -0
- package/.claude/worktrees/phase-2-mcp/backend/validate_evolution.py +267 -0
- package/.claude/worktrees/phase-2-mcp/components.json +28 -0
- package/.claude/worktrees/phase-2-mcp/docs/api/hermes-api.openapi.yaml +438 -0
- package/.claude/worktrees/phase-2-mcp/docs/hero.svg +148 -0
- package/.claude/worktrees/phase-2-mcp/eslint.config.mjs +18 -0
- package/.claude/worktrees/phase-2-mcp/install.sh +245 -0
- package/.claude/worktrees/phase-2-mcp/next-env.d.ts +6 -0
- package/.claude/worktrees/phase-2-mcp/next.config.ts +32 -0
- package/.claude/worktrees/phase-2-mcp/package-lock.json +11936 -0
- package/.claude/worktrees/phase-2-mcp/package.json +41 -0
- package/.claude/worktrees/phase-2-mcp/pnpm-workspace.yaml +4 -0
- package/.claude/worktrees/phase-2-mcp/postcss.config.mjs +7 -0
- package/.claude/worktrees/phase-2-mcp/public/file.svg +1 -0
- package/.claude/worktrees/phase-2-mcp/public/fonts/SF-Pro-Display-Bold.otf +0 -0
- package/.claude/worktrees/phase-2-mcp/public/fonts/SF-Pro-Display-Heavy.otf +0 -0
- package/.claude/worktrees/phase-2-mcp/public/fonts/SF-Pro-Display-Medium.otf +0 -0
- package/.claude/worktrees/phase-2-mcp/public/fonts/SF-Pro-Display-Regular.otf +0 -0
- package/.claude/worktrees/phase-2-mcp/public/fonts/SF-Pro-Display-Semibold.otf +0 -0
- package/.claude/worktrees/phase-2-mcp/public/fonts/SF-Pro-Text-Bold.otf +0 -0
- package/.claude/worktrees/phase-2-mcp/public/fonts/SF-Pro-Text-Heavy.otf +0 -0
- package/.claude/worktrees/phase-2-mcp/public/fonts/SF-Pro-Text-Medium.otf +0 -0
- package/.claude/worktrees/phase-2-mcp/public/fonts/SF-Pro-Text-Regular.otf +0 -0
- package/.claude/worktrees/phase-2-mcp/public/fonts/SF-Pro-Text-Semibold.otf +0 -0
- package/.claude/worktrees/phase-2-mcp/public/globe.svg +1 -0
- package/.claude/worktrees/phase-2-mcp/public/next.svg +1 -0
- package/.claude/worktrees/phase-2-mcp/public/theme-preview.html +257 -0
- package/.claude/worktrees/phase-2-mcp/public/vercel.svg +1 -0
- package/.claude/worktrees/phase-2-mcp/public/window.svg +1 -0
- package/.claude/worktrees/phase-2-mcp/run.sh +26 -0
- package/.claude/worktrees/phase-2-mcp/skills-lock.json +10 -0
- package/.claude/worktrees/phase-2-mcp/specs/event-schema.md +223 -0
- package/.claude/worktrees/phase-2-mcp/specs/examples/run.jsonl +3 -0
- package/.claude/worktrees/phase-2-mcp/src/app/api/[...path]/route.ts +55 -0
- package/.claude/worktrees/phase-2-mcp/src/app/api/auth/token/route.ts +22 -0
- package/.claude/worktrees/phase-2-mcp/src/app/evolution/page.tsx +589 -0
- package/.claude/worktrees/phase-2-mcp/src/app/favicon.ico +0 -0
- package/.claude/worktrees/phase-2-mcp/src/app/globals.css +321 -0
- package/.claude/worktrees/phase-2-mcp/src/app/layout.tsx +63 -0
- package/.claude/worktrees/phase-2-mcp/src/app/page.tsx +70 -0
- package/.claude/worktrees/phase-2-mcp/src/app/skills/page.tsx +369 -0
- package/.claude/worktrees/phase-2-mcp/src/components/ApiConfigCard.tsx +199 -0
- package/.claude/worktrees/phase-2-mcp/src/components/ColorBends.css +1 -0
- package/.claude/worktrees/phase-2-mcp/src/components/ColorBends.d.ts +1 -0
- package/.claude/worktrees/phase-2-mcp/src/components/ColorBends.jsx +1 -0
- package/.claude/worktrees/phase-2-mcp/src/components/CoreLoopToggle.tsx +111 -0
- package/.claude/worktrees/phase-2-mcp/src/components/EnvironmentStatus.tsx +176 -0
- package/.claude/worktrees/phase-2-mcp/src/components/EvolutionBackground.tsx +1 -0
- package/.claude/worktrees/phase-2-mcp/src/components/ReactQueryProvider.tsx +24 -0
- package/.claude/worktrees/phase-2-mcp/src/components/Sidebar.tsx +247 -0
- package/.claude/worktrees/phase-2-mcp/src/components/SkillDiffViewer.tsx +154 -0
- package/.claude/worktrees/phase-2-mcp/src/components/ThemeAwareBackground.tsx +67 -0
- package/.claude/worktrees/phase-2-mcp/src/components/ThemeToggle.tsx +54 -0
- package/.claude/worktrees/phase-2-mcp/src/components/WelcomeHero.tsx +77 -0
- package/.claude/worktrees/phase-2-mcp/src/components/bits/ClickSpark.tsx +116 -0
- package/.claude/worktrees/phase-2-mcp/src/components/bits/CountUp.tsx +98 -0
- package/.claude/worktrees/phase-2-mcp/src/components/bits/DarkSelect.tsx +95 -0
- package/.claude/worktrees/phase-2-mcp/src/components/bits/DecryptedText.tsx +161 -0
- package/.claude/worktrees/phase-2-mcp/src/components/bits/ElectricBorder.tsx +184 -0
- package/.claude/worktrees/phase-2-mcp/src/components/bits/GlitchText.tsx +34 -0
- package/.claude/worktrees/phase-2-mcp/src/components/bits/ShinyText.tsx +55 -0
- package/.claude/worktrees/phase-2-mcp/src/components/bits/SpotlightCard.tsx +42 -0
- package/.claude/worktrees/phase-2-mcp/src/components/bits/TextType.tsx +95 -0
- package/.claude/worktrees/phase-2-mcp/src/components/bits/index.ts +9 -0
- package/.claude/worktrees/phase-2-mcp/src/components/pages/CuratorPage.tsx +632 -0
- package/.claude/worktrees/phase-2-mcp/src/components/pages/DatasetPage.tsx +271 -0
- package/.claude/worktrees/phase-2-mcp/src/components/pages/EvolutionPage.tsx +676 -0
- package/.claude/worktrees/phase-2-mcp/src/components/pages/FunctionCallingPage.tsx +1 -0
- package/.claude/worktrees/phase-2-mcp/src/components/pages/LogsPage.tsx +272 -0
- package/.claude/worktrees/phase-2-mcp/src/components/pages/MetricsPage.tsx +246 -0
- package/.claude/worktrees/phase-2-mcp/src/components/pages/OverviewPage.tsx +420 -0
- package/.claude/worktrees/phase-2-mcp/src/components/pages/SettingsPage.tsx +88 -0
- package/.claude/worktrees/phase-2-mcp/src/components/pages/SkillStudioPage.tsx +376 -0
- package/.claude/worktrees/phase-2-mcp/src/components/ui/animated-theme-toggler.tsx +97 -0
- package/.claude/worktrees/phase-2-mcp/src/components/ui/button.tsx +67 -0
- package/.claude/worktrees/phase-2-mcp/src/components/ui/card.tsx +103 -0
- package/.claude/worktrees/phase-2-mcp/src/components/ui/input.tsx +19 -0
- package/.claude/worktrees/phase-2-mcp/src/components/ui/separator.tsx +28 -0
- package/.claude/worktrees/phase-2-mcp/src/components/ui/sheet.tsx +147 -0
- package/.claude/worktrees/phase-2-mcp/src/components/ui/sidebar.tsx +702 -0
- package/.claude/worktrees/phase-2-mcp/src/components/ui/skeleton.tsx +13 -0
- package/.claude/worktrees/phase-2-mcp/src/components/ui/theme-toggle.tsx +272 -0
- package/.claude/worktrees/phase-2-mcp/src/components/ui/tooltip.tsx +57 -0
- package/.claude/worktrees/phase-2-mcp/src/hooks/use-mobile.ts +19 -0
- package/.claude/worktrees/phase-2-mcp/src/lib/api.ts +455 -0
- package/.claude/worktrees/phase-2-mcp/src/lib/queryClient.ts +12 -0
- package/.claude/worktrees/phase-2-mcp/src/lib/utils.ts +6 -0
- package/.claude/worktrees/phase-2-mcp/stitch/agent_dashboard/DESIGN_SPEC.md +521 -0
- package/.claude/worktrees/phase-2-mcp/stitch/agent_dashboard/prototype.html +676 -0
- package/.claude/worktrees/phase-2-mcp/stitch/curator_workspace/code.html +448 -0
- package/.claude/worktrees/phase-2-mcp/stitch/curator_workspace/screen.png +0 -0
- package/.claude/worktrees/phase-2-mcp/stitch/datasets/code.html +479 -0
- package/.claude/worktrees/phase-2-mcp/stitch/datasets/screen.png +0 -0
- package/.claude/worktrees/phase-2-mcp/stitch/evolution_history/code.html +461 -0
- package/.claude/worktrees/phase-2-mcp/stitch/evolution_history/screen.png +0 -0
- package/.claude/worktrees/phase-2-mcp/stitch/hermes_dashboard/DESIGN.md +192 -0
- package/.claude/worktrees/phase-2-mcp/stitch/hermes_dashboard/DESIGN_SPEC.md +455 -0
- package/.claude/worktrees/phase-2-mcp/stitch/hermes_overview/code.html +399 -0
- package/.claude/worktrees/phase-2-mcp/stitch/hermes_overview/screen.png +0 -0
- package/.claude/worktrees/phase-2-mcp/stitch/live_logs/code.html +324 -0
- package/.claude/worktrees/phase-2-mcp/stitch/live_logs/screen.png +0 -0
- package/.claude/worktrees/phase-2-mcp/stitch/skill_hub/code.html +596 -0
- package/.claude/worktrees/phase-2-mcp/stitch/skill_hub/screen.png +0 -0
- package/.claude/worktrees/phase-2-mcp/stitch/system_metrics/code.html +527 -0
- package/.claude/worktrees/phase-2-mcp/stitch/system_metrics/screen.png +0 -0
- package/.claude/worktrees/phase-2-mcp/stitch/system_settings/code.html +257 -0
- package/.claude/worktrees/phase-2-mcp/stitch/system_settings/screen.png +0 -0
- package/.claude/worktrees/phase-2-mcp/test_dashboard.py +201 -0
- package/.claude/worktrees/phase-2-mcp/tests/collectors/__init__.py +0 -0
- package/.claude/worktrees/phase-2-mcp/tests/collectors/fixtures/sample_session.jsonl +7 -0
- package/.claude/worktrees/phase-2-mcp/tests/collectors/test_claude_code_collector.py +171 -0
- package/.claude/worktrees/phase-2-mcp/tests/collectors/test_hermes_collector.py +167 -0
- package/.claude/worktrees/phase-2-mcp/tests/eval/test_engine.py +234 -0
- package/.claude/worktrees/phase-2-mcp/tests/eval/test_scorers.py +249 -0
- package/.claude/worktrees/phase-2-mcp/tests/storage/__init__.py +0 -0
- package/.claude/worktrees/phase-2-mcp/tests/storage/test_run_store.py +359 -0
- package/.claude/worktrees/phase-2-mcp/tests/test_curator.py +559 -0
- package/.claude/worktrees/phase-2-mcp/tests/test_mcp_server.py +114 -0
- package/.claude/worktrees/phase-2-mcp/tsconfig.json +34 -0
- package/.env.example +72 -0
- package/.kilocode/package-lock.json +378 -0
- package/.kilocode/package.json +5 -0
- package/AGENTS.md +5 -0
- package/CLAUDE.md +29 -0
- package/QA_AUDIT_PLAN.md +156 -0
- package/README.md +355 -0
- package/agent-agnostic-evolution-dashboard.md +405 -0
- package/backend/__init__.py +0 -0
- package/backend/collectors/__init__.py +0 -0
- package/backend/collectors/claude_code_collector.py +277 -0
- package/backend/collectors/hermes_collector.py +68 -0
- package/backend/curator.py +512 -0
- package/backend/eval/__init__.py +19 -0
- package/backend/eval/engine.py +116 -0
- package/backend/eval/scorers.py +201 -0
- package/backend/generate_dataset.py +86 -0
- package/backend/job_tracker.py +232 -0
- package/backend/main.py +1746 -0
- package/backend/mcp_server.py +250 -0
- package/backend/promethean/__init__.py +24 -0
- package/backend/promethean/cycle_orchestrator.py +270 -0
- package/backend/promethean/delta_validator.py +191 -0
- package/backend/promethean/dspy_compiler.py +315 -0
- package/backend/promethean/gepa_strategist.py +213 -0
- package/backend/promethean/models.py +260 -0
- package/backend/promethean/skill_deployer.py +195 -0
- package/backend/promethean/trace_ingestion.py +142 -0
- package/backend/requirements.txt +6 -0
- package/backend/sdd_evolve.py +459 -0
- package/backend/skill_detector.py +227 -0
- package/backend/skill_registry.py +289 -0
- package/backend/storage/__init__.py +5 -0
- package/backend/storage/run_store.py +393 -0
- package/backend/storage/schema.sql +99 -0
- package/backend/validate_evolution.py +267 -0
- package/bin/genoma.js +250 -0
- package/components.json +28 -0
- package/docs/api/hermes-api.openapi.yaml +438 -0
- package/docs/hero.svg +148 -0
- package/eslint.config.mjs +18 -0
- package/install.sh +245 -0
- package/next-env.d.ts +6 -0
- package/next.config.ts +32 -0
- package/package.json +46 -0
- package/pnpm-workspace.yaml +4 -0
- package/postcss.config.mjs +7 -0
- package/public/file.svg +1 -0
- package/public/fonts/SF-Pro-Display-Bold.otf +0 -0
- package/public/fonts/SF-Pro-Display-Heavy.otf +0 -0
- package/public/fonts/SF-Pro-Display-Medium.otf +0 -0
- package/public/fonts/SF-Pro-Display-Regular.otf +0 -0
- package/public/fonts/SF-Pro-Display-Semibold.otf +0 -0
- package/public/fonts/SF-Pro-Text-Bold.otf +0 -0
- package/public/fonts/SF-Pro-Text-Heavy.otf +0 -0
- package/public/fonts/SF-Pro-Text-Medium.otf +0 -0
- package/public/fonts/SF-Pro-Text-Regular.otf +0 -0
- package/public/fonts/SF-Pro-Text-Semibold.otf +0 -0
- package/public/globe.svg +1 -0
- package/public/next.svg +1 -0
- package/public/theme-preview.html +257 -0
- package/public/vercel.svg +1 -0
- package/public/window.svg +1 -0
- package/run.sh +26 -0
- package/scripts/postinstall.js +50 -0
- package/skills-lock.json +10 -0
- package/specs/event-schema.md +223 -0
- package/specs/examples/run.jsonl +3 -0
- package/src/app/api/[...path]/route.ts +55 -0
- package/src/app/api/auth/token/route.ts +22 -0
- package/src/app/evolution/page.tsx +589 -0
- package/src/app/favicon.ico +0 -0
- package/src/app/globals.css +321 -0
- package/src/app/layout.tsx +63 -0
- package/src/app/page.tsx +70 -0
- package/src/app/skills/page.tsx +369 -0
- package/src/components/ApiConfigCard.tsx +199 -0
- package/src/components/ColorBends.css +1 -0
- package/src/components/ColorBends.d.ts +1 -0
- package/src/components/ColorBends.jsx +1 -0
- package/src/components/CoreLoopToggle.tsx +111 -0
- package/src/components/EnvironmentStatus.tsx +176 -0
- package/src/components/EvolutionBackground.tsx +1 -0
- package/src/components/ReactQueryProvider.tsx +24 -0
- package/src/components/Sidebar.tsx +247 -0
- package/src/components/SkillDiffViewer.tsx +154 -0
- package/src/components/ThemeAwareBackground.tsx +67 -0
- package/src/components/ThemeToggle.tsx +54 -0
- package/src/components/WelcomeHero.tsx +77 -0
- package/src/components/bits/ClickSpark.tsx +116 -0
- package/src/components/bits/CountUp.tsx +98 -0
- package/src/components/bits/DarkSelect.tsx +95 -0
- package/src/components/bits/DecryptedText.tsx +161 -0
- package/src/components/bits/ElectricBorder.tsx +184 -0
- package/src/components/bits/GlitchText.tsx +34 -0
- package/src/components/bits/ShinyText.tsx +55 -0
- package/src/components/bits/SpotlightCard.tsx +42 -0
- package/src/components/bits/TextType.tsx +95 -0
- package/src/components/bits/index.ts +9 -0
- package/src/components/pages/CuratorPage.tsx +632 -0
- package/src/components/pages/DatasetPage.tsx +271 -0
- package/src/components/pages/EvolutionPage.tsx +676 -0
- package/src/components/pages/FunctionCallingPage.tsx +1 -0
- package/src/components/pages/LogsPage.tsx +272 -0
- package/src/components/pages/MetricsPage.tsx +246 -0
- package/src/components/pages/OverviewPage.tsx +420 -0
- package/src/components/pages/SettingsPage.tsx +88 -0
- package/src/components/pages/SkillStudioPage.tsx +376 -0
- package/src/components/ui/animated-theme-toggler.tsx +97 -0
- package/src/components/ui/button.tsx +67 -0
- package/src/components/ui/card.tsx +103 -0
- package/src/components/ui/input.tsx +19 -0
- package/src/components/ui/separator.tsx +28 -0
- package/src/components/ui/sheet.tsx +147 -0
- package/src/components/ui/sidebar.tsx +702 -0
- package/src/components/ui/skeleton.tsx +13 -0
- package/src/components/ui/theme-toggle.tsx +272 -0
- package/src/components/ui/tooltip.tsx +57 -0
- package/src/hooks/use-mobile.ts +19 -0
- package/src/lib/api.ts +455 -0
- package/src/lib/queryClient.ts +12 -0
- package/src/lib/utils.ts +6 -0
- package/stitch/agent_dashboard/DESIGN_SPEC.md +521 -0
- package/stitch/agent_dashboard/prototype.html +676 -0
- package/stitch/curator_workspace/code.html +448 -0
- package/stitch/curator_workspace/screen.png +0 -0
- package/stitch/datasets/code.html +479 -0
- package/stitch/datasets/screen.png +0 -0
- package/stitch/evolution_history/code.html +461 -0
- package/stitch/evolution_history/screen.png +0 -0
- package/stitch/hermes_dashboard/DESIGN.md +192 -0
- package/stitch/hermes_dashboard/DESIGN_SPEC.md +455 -0
- package/stitch/hermes_overview/code.html +399 -0
- package/stitch/hermes_overview/screen.png +0 -0
- package/stitch/live_logs/code.html +324 -0
- package/stitch/live_logs/screen.png +0 -0
- package/stitch/skill_hub/code.html +596 -0
- package/stitch/skill_hub/screen.png +0 -0
- package/stitch/system_metrics/code.html +527 -0
- package/stitch/system_metrics/screen.png +0 -0
- package/stitch/system_settings/code.html +257 -0
- package/stitch/system_settings/screen.png +0 -0
- package/test_dashboard.py +201 -0
- package/tests/collectors/__init__.py +0 -0
- package/tests/collectors/fixtures/sample_session.jsonl +7 -0
- package/tests/collectors/test_claude_code_collector.py +171 -0
- package/tests/collectors/test_hermes_collector.py +167 -0
- package/tests/eval/test_engine.py +234 -0
- package/tests/eval/test_scorers.py +249 -0
- package/tests/storage/__init__.py +0 -0
- package/tests/storage/test_run_store.py +359 -0
- package/tests/test_curator.py +559 -0
- package/tests/test_e2e_npm.py +621 -0
- package/tests/test_mcp_server.py +114 -0
- package/tsconfig.json +34 -0
|
@@ -0,0 +1,273 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: job_tracker
|
|
3
|
+
summary: ''
|
|
4
|
+
tags: []
|
|
5
|
+
related: []
|
|
6
|
+
keywords: []
|
|
7
|
+
createdAt: '2026-04-28T01:33:30.561Z'
|
|
8
|
+
updatedAt: '2026-04-28T01:33:30.561Z'
|
|
9
|
+
---
|
|
10
|
+
## Reason
|
|
11
|
+
Preserving complete backend/job_tracker.py from hermes-dashboard project
|
|
12
|
+
|
|
13
|
+
## Raw Concept
|
|
14
|
+
**Task:**
|
|
15
|
+
Preserve backend/job_tracker.py
|
|
16
|
+
|
|
17
|
+
**Files:**
|
|
18
|
+
- backend/job_tracker.py
|
|
19
|
+
|
|
20
|
+
**Timestamp:** 2026-04-28
|
|
21
|
+
|
|
22
|
+
**Patterns:**
|
|
23
|
+
- `class JobStatus` - Python class definition
|
|
24
|
+
- `class EvolutionJob` - Python class definition
|
|
25
|
+
- `class JobTracker` - Python class definition
|
|
26
|
+
|
|
27
|
+
## Narrative
|
|
28
|
+
### Structure
|
|
29
|
+
Python file with 3 classes and 0 functions
|
|
30
|
+
|
|
31
|
+
### Dependencies
|
|
32
|
+
Classes: JobStatus, EvolutionJob, JobTracker
|
|
33
|
+
|
|
34
|
+
### Highlights
|
|
35
|
+
Source: hermes-dashboard/backend/job_tracker.py
|
|
36
|
+
|
|
37
|
+
---
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
"""Evolution job tracking — persistent state for active and completed jobs."""
|
|
41
|
+
|
|
42
|
+
import json
|
|
43
|
+
import re
|
|
44
|
+
import uuid
|
|
45
|
+
import asyncio
|
|
46
|
+
from datetime import datetime
|
|
47
|
+
from enum import Enum
|
|
48
|
+
from pathlib import Path
|
|
49
|
+
from dataclasses import dataclass, field, asdict
|
|
50
|
+
from typing import Optional
|
|
51
|
+
|
|
52
|
+
LOG_DIR = Path.home() / ".hermes" / "evolution-logs"
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
class JobStatus(str, Enum):
|
|
56
|
+
QUEUED = "queued"
|
|
57
|
+
LOADING_SKILL = "loading_skill"
|
|
58
|
+
BUILDING_DATASET = "building_dataset"
|
|
59
|
+
VALIDATING = "validating"
|
|
60
|
+
CONFIGURING = "configuring"
|
|
61
|
+
OPTIMIZING = "optimizing"
|
|
62
|
+
EVALUATING = "evaluating"
|
|
63
|
+
SAVING = "saving"
|
|
64
|
+
COMPLETED = "completed"
|
|
65
|
+
FAILED = "failed"
|
|
66
|
+
|
|
67
|
+
|
|
68
|
+
# Phases in order (for progress calculation)
|
|
69
|
+
PHASE_ORDER = [
|
|
70
|
+
JobStatus.LOADING_SKILL,
|
|
71
|
+
JobStatus.BUILDING_DATASET,
|
|
72
|
+
JobStatus.VALIDATING,
|
|
73
|
+
JobStatus.CONFIGURING,
|
|
74
|
+
JobStatus.OPTIMIZING,
|
|
75
|
+
JobStatus.EVALUATING,
|
|
76
|
+
JobStatus.SAVING,
|
|
77
|
+
]
|
|
78
|
+
|
|
79
|
+
|
|
80
|
+
@dataclass
|
|
81
|
+
class EvolutionJob:
|
|
82
|
+
id: str
|
|
83
|
+
skill_name: str
|
|
84
|
+
status: JobStatus = JobStatus.QUEUED
|
|
85
|
+
iterations: int = 3
|
|
86
|
+
current_iteration: int = 0
|
|
87
|
+
pid: Optional[int] = None
|
|
88
|
+
started_at: str = ""
|
|
89
|
+
completed_at: str = ""
|
|
90
|
+
baseline_score: Optional[float] = None
|
|
91
|
+
current_best_score: Optional[float] = None
|
|
92
|
+
evolved_score: Optional[float] = None
|
|
93
|
+
improvement: Optional[float] = None
|
|
94
|
+
error: str = ""
|
|
95
|
+
logs: list[str] = field(default_factory=list)
|
|
96
|
+
|
|
97
|
+
def to_dict(self) -> dict:
|
|
98
|
+
d = asdict(self)
|
|
99
|
+
d["status"] = self.status.value
|
|
100
|
+
return d
|
|
101
|
+
|
|
102
|
+
@property
|
|
103
|
+
def progress(self) -> float:
|
|
104
|
+
"""0.0 to 1.0 progress estimate."""
|
|
105
|
+
if self.status == JobStatus.COMPLETED:
|
|
106
|
+
return 1.0
|
|
107
|
+
if self.status == JobStatus.FAILED:
|
|
108
|
+
return 0.0
|
|
109
|
+
if self.status == JobStatus.QUEUED:
|
|
110
|
+
return 0.0
|
|
111
|
+
|
|
112
|
+
# Phase-based progress
|
|
113
|
+
phase_idx = 0
|
|
114
|
+
try:
|
|
115
|
+
phase_idx = PHASE_ORDER.index(self.status)
|
|
116
|
+
except ValueError:
|
|
117
|
+
pass
|
|
118
|
+
|
|
119
|
+
phase_weight = 1.0 / len(PHASE_ORDER)
|
|
120
|
+
|
|
121
|
+
# Within OPTIMIZING phase, use iteration progress
|
|
122
|
+
if self.status == JobStatus.OPTIMIZING and self.iterations > 0:
|
|
123
|
+
iter_progress = self.current_iteration / self.iterations
|
|
124
|
+
base = phase_idx * phase_weight
|
|
125
|
+
return base + (iter_progress * phase_weight)
|
|
126
|
+
|
|
127
|
+
return phase_idx * phase_weight
|
|
128
|
+
|
|
129
|
+
def add_log(self, message: str):
|
|
130
|
+
timestamp = datetime.now().isoformat()[:19]
|
|
131
|
+
self.logs.append(f"[{timestamp}] {message}")
|
|
132
|
+
# Keep last 500 lines
|
|
133
|
+
if len(self.logs) > 500:
|
|
134
|
+
self.logs = self.logs[-500:]
|
|
135
|
+
|
|
136
|
+
def save_log(self):
|
|
137
|
+
LOG_DIR.mkdir(parents=True, exist_ok=True)
|
|
138
|
+
log_file = LOG_DIR / f"{self.id}.json"
|
|
139
|
+
log_file.write_text(json.dumps(self.to_dict(), indent=2))
|
|
140
|
+
|
|
141
|
+
|
|
142
|
+
class JobTracker:
|
|
143
|
+
def __init__(self):
|
|
144
|
+
self._jobs: dict[str, EvolutionJob] = {}
|
|
145
|
+
self._processes: dict[str, asyncio.subprocess.Process] = {}
|
|
146
|
+
LOG_DIR.mkdir(parents=True, exist_ok=True)
|
|
147
|
+
|
|
148
|
+
def create_job(self, skill_name: str, iterations: int) -> EvolutionJob:
|
|
149
|
+
job_id = f"{skill_name}_{datetime.now().strftime('%Y%m%d_%H%M%S')}_{uuid.uuid4().hex[:6]}"
|
|
150
|
+
job = EvolutionJob(
|
|
151
|
+
id=job_id,
|
|
152
|
+
skill_name=skill_name,
|
|
153
|
+
iterations=iterations,
|
|
154
|
+
started_at=datetime.now().isoformat(),
|
|
155
|
+
)
|
|
156
|
+
self._jobs[job_id] = job
|
|
157
|
+
return job
|
|
158
|
+
|
|
159
|
+
def get_job(self, job_id: str) -> Optional[EvolutionJob]:
|
|
160
|
+
return self._jobs.get(job_id)
|
|
161
|
+
|
|
162
|
+
def get_active_jobs(self) -> list[EvolutionJob]:
|
|
163
|
+
return [
|
|
164
|
+
j for j in self._jobs.values()
|
|
165
|
+
if j.status not in (JobStatus.COMPLETED, JobStatus.FAILED)
|
|
166
|
+
]
|
|
167
|
+
|
|
168
|
+
def get_all_jobs(self, limit: int = 50) -> list[EvolutionJob]:
|
|
169
|
+
sorted_jobs = sorted(
|
|
170
|
+
self._jobs.values(),
|
|
171
|
+
key=lambda j: j.started_at,
|
|
172
|
+
reverse=True,
|
|
173
|
+
)
|
|
174
|
+
return sorted_jobs[:limit]
|
|
175
|
+
|
|
176
|
+
def set_process(self, job_id: str, process: asyncio.subprocess.Process):
|
|
177
|
+
self._processes[job_id] = process
|
|
178
|
+
|
|
179
|
+
def get_process(self, job_id: str) -> Optional[asyncio.subprocess.Process]:
|
|
180
|
+
return self._processes.get(job_id)
|
|
181
|
+
|
|
182
|
+
def cleanup_process(self, job_id: str):
|
|
183
|
+
self._processes.pop(job_id, None)
|
|
184
|
+
|
|
185
|
+
# ── Log parsing ─────────────────────────────────────────────────
|
|
186
|
+
|
|
187
|
+
# Patterns to detect phase changes from Rich output
|
|
188
|
+
PHASE_PATTERNS = [
|
|
189
|
+
(r"Loaded:.*\.md", JobStatus.LOADING_SKILL),
|
|
190
|
+
(r"Building evaluation dataset", JobStatus.BUILDING_DATASET),
|
|
191
|
+
(r"Generated.*synthetic examples", JobStatus.BUILDING_DATASET),
|
|
192
|
+
(r"Mined.*examples from session", JobStatus.BUILDING_DATASET),
|
|
193
|
+
(r"Loaded golden dataset", JobStatus.BUILDING_DATASET),
|
|
194
|
+
(r"Validating baseline constraints", JobStatus.VALIDATING),
|
|
195
|
+
(r"Configuring optimizer", JobStatus.CONFIGURING),
|
|
196
|
+
(r"Running GEPA optimization", JobStatus.OPTIMIZING),
|
|
197
|
+
(r"Running MIPROv2", JobStatus.OPTIMIZING),
|
|
198
|
+
(r"Optimization completed", JobStatus.OPTIMIZING),
|
|
199
|
+
(r"Validating evolved skill", JobStatus.EVALUATING),
|
|
200
|
+
(r"Evaluating on holdout", JobStatus.EVALUATING),
|
|
201
|
+
(r"Evolution Results", JobStatus.SAVING),
|
|
202
|
+
(r"Saved.*to output", JobStatus.SAVING),
|
|
203
|
+
(r"✓ Skill evolved", JobStatus.COMPLETED),
|
|
204
|
+
]
|
|
205
|
+
|
|
206
|
+
# Pattern to extract scores
|
|
207
|
+
SCORE_PATTERN = re.compile(r"baseline[=_:\s]+(\d+\.?\d*)|evolved[=_:\s]+(\d+\.?\d*)|score[=_:\s]+(\d+\.?\d*)|improvement[=_:\s]+([+-]?\d+\.?\d*)", re.IGNORECASE)
|
|
208
|
+
|
|
209
|
+
# Pattern to extract iteration number
|
|
210
|
+
ITER_PATTERN = re.compile(r"iteration[=:\s]+(\d+)|eval[=:\s#]+(\d+)/(\d+)", re.IGNORECASE)
|
|
211
|
+
|
|
212
|
+
def parse_line(self, job: EvolutionJob, line: str):
|
|
213
|
+
"""Parse a log line and update job state."""
|
|
214
|
+
# Strip ANSI codes
|
|
215
|
+
clean = re.sub(r"\x1b\[[0-9;]*m", "", line).strip()
|
|
216
|
+
if not clean:
|
|
217
|
+
return
|
|
218
|
+
|
|
219
|
+
job.add_log(clean)
|
|
220
|
+
|
|
221
|
+
# Check phase transitions
|
|
222
|
+
for pattern, phase in self.PHASE_PATTERNS:
|
|
223
|
+
if re.search(pattern, clean, re.IGNORECASE):
|
|
224
|
+
if phase != job.status:
|
|
225
|
+
job.status = phase
|
|
226
|
+
|
|
227
|
+
# Check for optimization iteration progress
|
|
228
|
+
iter_match = self.ITER_PATTERN.search(clean)
|
|
229
|
+
if iter_match:
|
|
230
|
+
num = iter_match.group(1) or iter_match.group(2)
|
|
231
|
+
if num:
|
|
232
|
+
job.current_iteration = int(num)
|
|
233
|
+
total = iter_match.group(3)
|
|
234
|
+
if total:
|
|
235
|
+
job.iterations = int(total)
|
|
236
|
+
|
|
237
|
+
# Check for scores
|
|
238
|
+
score_match = self.SCORE_PATTERN.search(clean)
|
|
239
|
+
if score_match:
|
|
240
|
+
val = score_match.group(1) or score_match.group(2) or score_match.group(3) or score_match.group(4)
|
|
241
|
+
if val:
|
|
242
|
+
try:
|
|
243
|
+
score = float(val)
|
|
244
|
+
if "baseline" in clean.lower():
|
|
245
|
+
job.baseline_score = score
|
|
246
|
+
elif "evolved" in clean.lower() or "best" in clean.lower():
|
|
247
|
+
job.current_best_score = score
|
|
248
|
+
elif "improvement" in clean.lower():
|
|
249
|
+
job.improvement = score
|
|
250
|
+
except ValueError:
|
|
251
|
+
pass
|
|
252
|
+
|
|
253
|
+
# Check for completion
|
|
254
|
+
if "evolved_skill.md" in clean and "Saved" in clean:
|
|
255
|
+
job.status = JobStatus.COMPLETED
|
|
256
|
+
job.completed_at = datetime.now().isoformat()
|
|
257
|
+
|
|
258
|
+
# Check for failure
|
|
259
|
+
if "FAILED" in clean or "not found" in clean.lower():
|
|
260
|
+
if "✗" in clean or "Error" in clean or "error" in clean:
|
|
261
|
+
job.error = clean
|
|
262
|
+
job.status = JobStatus.FAILED
|
|
263
|
+
job.completed_at = datetime.now().isoformat()
|
|
264
|
+
|
|
265
|
+
# Persist periodically
|
|
266
|
+
if len(job.logs) % 10 == 0:
|
|
267
|
+
job.save_log()
|
|
268
|
+
|
|
269
|
+
|
|
270
|
+
# Global tracker instance
|
|
271
|
+
tracker = JobTracker()
|
|
272
|
+
|
|
273
|
+
|
package/.claude/worktrees/phase-2-mcp/.brv/context-tree/backend/backend/job_tracker.overview.md
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
## job_tracker.py Overview
|
|
2
|
+
|
|
3
|
+
### Key Points
|
|
4
|
+
|
|
5
|
+
- **Three core classes**: `JobStatus` (Enum with 11 job states), `EvolutionJob` (dataclass storing job metadata), and `JobTracker` (manages job lifecycle)
|
|
6
|
+
- **Phase-based progress tracking**: Jobs progress through 7 ordered phases (LOADING_SKILL → SAVING), with progress calculated as 0.0–1.0 based on current phase and iteration count
|
|
7
|
+
- **Log parsing via regex**: `JobTracker.parse_line()` detects phase transitions, scores, iterations, and completion/failure from Rich console output
|
|
8
|
+
- **Persistent state**: Jobs saved to JSON in `~/.hermes/evolution-logs/{job_id}.json`; logs capped at 500 lines
|
|
9
|
+
- **Async process management**: `JobTracker` stores `asyncio.subprocess.Process` objects per job
|
|
10
|
+
- **Global singleton**: Module exposes `tracker = JobTracker()` instance
|
|
11
|
+
|
|
12
|
+
### Structure / Sections Summary
|
|
13
|
+
|
|
14
|
+
| Section | Description |
|
|
15
|
+
|---------|-------------|
|
|
16
|
+
| **Imports** | Standard library: `json`, `re`, `uuid`, `asyncio`, `datetime`, `Enum`, `Path`, `dataclasses` |
|
|
17
|
+
| **JobStatus Enum** | 11 states: QUEUED, LOADING_SKILL, BUILDING_DATASET, VALIDATING, CONFIGURING, OPTIMIZING, EVALUATING, SAVING, COMPLETED, FAILED |
|
|
18
|
+
| **PHASE_ORDER** | List defining execution order for progress calculation |
|
|
19
|
+
| **EvolutionJob dataclass** | Fields: id, skill_name, status, iterations, current_iteration, pid, timestamps, scores (baseline/current_best/evolved), improvement, error, logs. Methods: `to_dict()`, `progress` property, `add_log()`, `save_log()` |
|
|
20
|
+
| **JobTracker class** | In-memory job storage (`_jobs`, `_processes` dicts). Methods: `create_job()`, `get_job()`, `get_active_jobs()`, `get_all_jobs()`, process management, `parse_line()` |
|
|
21
|
+
| **Log parsing** | `PHASE_PATTERNS` (15 regex patterns for phase detection), `SCORE_PATTERN`, `ITER_PATTERN` |
|
|
22
|
+
|
|
23
|
+
### Notable Entities, Patterns, and Decisions
|
|
24
|
+
|
|
25
|
+
- **Pattern**: Dataclass with `asdict()` conversion for serialization
|
|
26
|
+
- **Pattern**: `JobStatus` extends both `str` and `Enum` for JSON-friendly serialization
|
|
27
|
+
- **Pattern**: Regex-based log parsing with ANSI code stripping (`\x1b\[[0-9;]*m`)
|
|
28
|
+
- **Decision**: Progress within OPTIMIZING phase uses iteration ratio (`current_iteration / iterations`)
|
|
29
|
+
- **Decision**: Logs persisted every 10 lines for balance between durability and I/O
|
|
30
|
+
- **Entity**: `LOG_DIR = Path.home() / ".hermes" / "evolution-logs"` — centralized log storage
|
|
31
|
+
- **Entity**: Job IDs format: `{skill_name}_{YYYYMMDD_HHMMSS}_{6-char-uuid}`
|
|
File without changes
|