Commit graph

9 commits

Author SHA1 Message Date
Snider
1ef8157822 fix: truncate oversized sections and clear DB on fresh ingest
Some checks failed
CI / PHP 8.3 (push) Failing after 2s
CI / PHP 8.4 (push) Failing after 2s
- Truncate content to 3800 chars before embedding (embeddinggemma has
  a 2048-token context, ~4K char limit). Eliminates all 73 Ollama 500
  errors from oversized plan sections.
- Clear brain_memories DB table when --fresh is used, keeping DB rows
  in sync with Qdrant vectors.

Co-Authored-By: Virgil <virgil@lethean.io>
2026-03-03 16:02:11 +00:00
Snider
9623e1e0b5 feat: add brain:ingest command for comprehensive knowledge archival
Some checks failed
CI / PHP 8.3 (push) Failing after 2s
CI / PHP 8.4 (push) Failing after 2s
Discovers markdown across 4 source types:
- memory: ~/.claude/projects memory files
- plans: docs/plans across repos + ~/.claude/plans
- claude-md: CLAUDE.md repo instructions
- tasks: core/tasks research and ideas

Supports --fresh to clear collection, --dry-run for preview,
and --source to target specific types.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 11:10:37 +00:00
Snider
20a0b584ae fix: remove glob path from docblock that broke PHP tokenizer
Some checks failed
CI / PHP 8.3 (push) Failing after 2s
CI / PHP 8.4 (push) Failing after 2s
The `*/` in `projects/*/memory/` was closing the docblock comment
early, causing PHP to see `for` as a keyword on the same line.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-03 10:49:30 +00:00
Snider
dfd3dde7b1 feat(brain): add brain:seed-memory artisan command
Some checks failed
CI / PHP 8.3 (push) Failing after 2s
CI / PHP 8.4 (push) Failing after 2s
Scans ~/.claude/projects/*/memory/ for MEMORY.md and topic markdown
files, parses sections, infers memory types, and imports into
OpenBrain via BrainService::remember().

Supports --dry-run, --workspace, --agent, and --path options.

Co-Authored-By: Virgil <virgil@lethean.io>
2026-03-03 09:53:28 +00:00
cc1c4c1adc feat: add plan archival with retention policy (#34)
Some checks failed
CI / PHP 8.3 (pull_request) Failing after 21s
CI / PHP 8.4 (pull_request) Failing after 19s
- Add `agentic.plan_retention_days` config (default 90 days via AGENTIC_PLAN_RETENTION_DAYS env)
- Add SoftDeletes and `archived_at` timestamp to AgentPlan model
- Add migration for `deleted_at` and `archived_at` columns on agent_plans
- Create `agentic:plan-cleanup` command with --dry-run and --days options
- Schedule retention cleanup to run daily via service provider
- Register PlanRetentionCommand in ConsoleBooting handler
- Add PlanRetentionTest feature test suite covering all retention scenarios
- Fix archive() to store archived_at as dedicated column (not metadata string)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-02-23 15:11:55 +00:00
Claude
3f905583a8
chore: fix pint code style and add test config
Some checks failed
CI / tests (push) Failing after 1m9s
Add phpunit.xml for standalone test execution.
Apply Laravel Pint formatting fixes across all source files.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-23 03:50:09 +00:00
Snider
a2a9423ad6 security: fix SQL injection and add workspace scoping to MCP tools
- Replace orderByRaw with parameterised CASE statements
- Add Task::scopeOrderByPriority() and scopeOrderByStatus()
- Add AgentPlan::scopeOrderByStatus()
- Add workspace validation to StateSet, StateGet, StateList tools
- Add workspace validation to PlanGet, PlanList tools
- Add SecurityTest.php with comprehensive isolation tests

Fixes SEC-002, SEC-003 from security audit.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-29 12:21:01 +00:00
Snider
ad83825f93 refactor: rename namespace Core\Agentic to Core\Mod\Agentic
Updates all classes to use the new modular namespace convention.
Adds Service/ layer with Core\Service\Agentic for service definition.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-27 16:12:58 +00:00
Snider
1350472d11 monorepo sepration 2026-01-27 00:28:29 +00:00