54 Commits

Author SHA1 Message Date
1328b3cc94 Merge pull request 'ci: Gitea Actions — CI build/test + cross-platform release on tags' (#22) from feat/gitea-actions into main
All checks were successful
CI / build-and-test (push) Successful in -30m49s
Reviewed-on: #22
v0.0.1
2026-04-04 14:37:08 +00:00
SGC
87a62c0d6c ci: add Gitea Actions — CI on push/PR, release on version tags
Some checks failed
CI / build-and-test (pull_request) Failing after -31m8s
CI / build-and-test (push) Successful in -28m7s
- .gitea/workflows/ci.yml: build + test on every push and PR
- .gitea/workflows/release.yml: cross-platform release binaries on v*.*.* tags
  - Builds amcs-server and amcs-cli for linux/amd64, linux/arm64, darwin/amd64, darwin/arm64, windows/amd64
  - Embeds version, commit, and build date via ldflags
  - Creates Gitea Release with all binaries and checksums.txt attached
2026-04-04 16:28:19 +02:00
3e09dc0ac6 Merge pull request 'feat: amcs-cli — MCP tool CLI and stdio bridge' (#21) from feat/amcs-cli into main 2026-04-04 14:25:04 +00:00
SGC
b59e02aebe feat: add amcs-cli — MCP tool CLI and stdio bridge
- cmd/amcs-cli: new CLI tool for human/AI MCP tool access
- amcs-cli tools: list all tools from remote MCP server
- amcs-cli call <tool> --arg k=v: invoke a tool, print JSON/YAML result
- amcs-cli stdio: stdio→HTTP MCP bridge for AI clients
- Config: ~/.config/amcs/config.yaml, AMCS_URL/AMCS_TOKEN env vars, --server/--token flags
- Token never logged in errors
- Makefile: add build-cli target

Closes #18
2026-04-04 16:14:25 +02:00
4713110e32 Merge pull request 'feat: DBML schema files + relspecgo migration generation' (#20) from feat/dbml-schema-relspecgo into main
Reviewed-on: #20
Reviewed-by: Warky <hein.puth@gmail.com>
2026-04-04 13:37:26 +00:00
SGC
6c6b49b45c fix: add cross-file Ref declarations for relspecgo merge
- Add explicit Ref: blocks at bottom of each DBML file for cross-file FK relationships
- files.dbml: stored_files → thoughts, projects
- skills.dbml: project_skills/project_guardrails → projects
- meta.dbml: chat_histories → projects
- Update Makefile to use the relspec merge workflow where applicable
- Regenerate 020_generated_schema.sql with proper cross-file constraints

Addresses review comment on PR #20
2026-04-04 15:13:50 +02:00
SGC
59c43188e5 feat: add DBML schema files and relspecgo migration generation
- Add schema/*.dbml covering all existing tables (001-019)
- Wire relspecgo via make generate-migrations target
- Add make check-schema-drift for CI drift detection
- Add schema/README.md documenting the DBML-first workflow

Closes #19
2026-04-04 14:53:33 +02:00
f0e242293f Merge pull request 'feat(app): add lightweight status access tracking' (#16) from feat/status-page-access-tracking into main
Reviewed-on: #16
2026-04-04 12:25:25 +00:00
Jack O'Neill
50870dd369 feat(app): add lightweight status access tracking 2026-04-04 14:16:02 +02:00
b93f1d14f0 Merge pull request 'docs: audit plan/todo docs against current repo state' (#15) from docs/plan-todo-audit into main
Reviewed-on: #15
2026-04-03 11:38:59 +00:00
Jack O'Neill
7c41a3e846 docs: audit plan and todo status 2026-04-03 13:37:45 +02:00
Hein
d1d140e464 fix(tools): add hint for project_not_found error 2026-04-02 16:36:15 +02:00
Hein
9cfcb5621b feat(mcp): add new tools to the registered tools list 2026-04-02 13:53:11 +02:00
Hein
d0bfdbfbab feat(mcp): add describe_tools and annotate_tool functionality
* Implement DescribeTool for listing available MCP tools with annotations.
* Add UpsertToolAnnotation and GetToolAnnotations methods for managing tool notes.
* Create tool_annotations table for storing tool usage notes.
2026-04-02 13:51:09 +02:00
24532ef380 Merge pull request 'fix: correct chat_histories FK to reference projects(guid)' (#3) from fix/chat-history-fk into main
Reviewed-on: #3
2026-04-01 14:29:10 +00:00
sam
9407c05535 fix: remove migration 019, table was dropped manually 2026-04-01 16:28:44 +02:00
sam
f163b9c370 fix: correct chat_histories FK to reference projects(guid)
Fixes #2 — project_id on chat_histories was referencing projects(id)
(bigserial) instead of projects(guid) (uuid). Added migration 019 to
repair existing deployments and corrected 018 for fresh installs.
2026-04-01 16:25:26 +02:00
4fdd1411b2 Merge pull request 'feat: add chat history MCP tools' (#1) from feature/chat-history into main
Reviewed-on: #1
2026-04-01 14:15:19 +00:00
sam
4168154c42 fix: add chat_histories grant to rls_and_grants migration 2026-04-01 16:12:12 +02:00
sam
741a09017b feat: add chat history MCP tools
Adds save/get/list/delete tools for persisting and retrieving agent
chat histories in AMCS.

Changes:
- migrations/018_chat_histories.sql: new chat_histories table with
  indexes on session_id, project_id, channel, agent_id, created_at,
  and FTS over title+summary
- internal/types/extensions.go: ChatMessage and ChatHistory types
- internal/store/chat_histories.go: SaveChatHistory, GetChatHistory,
  GetChatHistoryBySessionID, ListChatHistories, DeleteChatHistory
- internal/tools/chat_history.go: ChatHistoryTool with four handlers
  (save_chat_history, get_chat_history, list_chat_histories,
  delete_chat_history)
- internal/mcpserver/server.go: ChatHistory field in ToolSet,
  registerChatHistoryTools registration function
- internal/app/app.go: wire ChatHistoryTool into ToolSet
2026-04-01 16:06:56 +02:00
Hein
bb759f4683 chore(tests): add new tests for tool registration and resource templates 2026-03-31 17:24:54 +02:00
Hein
f41c512f36 test(tools): add unit tests for error handling functions
* Implement tests for error functions like errRequiredField, errInvalidField, and errEntityNotFound.
* Ensure proper metadata is returned for various error scenarios.
* Validate error handling in CRM, Files, and other tools.
* Introduce tests for parsing stored file IDs and UUIDs.
* Enhance coverage for helper functions related to project resolution and session management.
2026-03-31 15:10:07 +02:00
acd780ac9c feat(files): introduce upload_file tool for staging files and enhance save_file documentation 2026-03-31 00:30:56 +02:00
3819eb4fee feat(files): update save_file tool description and enforce size limit for base64 payloads 2026-03-31 00:20:36 +02:00
4bd3c4e0ba feat(logging): enhance logging for metadata extraction and MCP tool handling 2026-03-31 00:16:13 +02:00
8f734c0556 feat(files): enhance file handling with support for HTTP uploads and direct binary access 2026-03-31 00:04:36 +02:00
3c1ca83dc9 feat: add agent skills and guardrails functionality
- Introduced new tools for managing agent skills and guardrails, including add, remove, and list operations.
- Updated README.md to document new commands and usage patterns for skills and guardrails.
- Enhanced server configuration to support longer read and write timeouts.
- Increased maximum upload size for files to 100 MB and adjusted related configurations.
- Created database migrations for agent skills, guardrails, and their associations with projects.
- Updated relevant code files to integrate new skills and guardrails into the application logic.
2026-03-30 23:35:54 +02:00
e6f00ce636 feat(metadata): enhance metadata handling by sanitizing extracted data and updating documentation for file storage 2026-03-30 23:14:08 +02:00
72b4f7ce3d feat: implement file upload handler and related functionality
- Added file upload handler to process both multipart and raw file uploads.
- Implemented parsing logic for upload requests, including handling file metadata.
- Introduced SaveFileDecodedInput structure for handling decoded file uploads.
- Created unit tests for file upload parsing and validation.

feat: add metadata retry configuration and functionality

- Introduced MetadataRetryConfig to the application configuration.
- Implemented MetadataRetryer to handle retrying metadata extraction for thoughts.
- Added new tool for retrying failed metadata extractions.
- Updated thought metadata structure to include status and timestamps for metadata processing.

fix: enhance metadata normalization and error handling

- Updated metadata normalization functions to track status and errors.
- Improved handling of metadata extraction failures during thought updates and captures.
- Ensured that metadata status is correctly set during various operations.

refactor: streamline file saving logic in FilesTool

- Refactored Save method in FilesTool to utilize new SaveDecoded method.
- Simplified project and thought ID resolution logic during file saving.
2026-03-30 22:57:21 +02:00
7f2b2b9fee feat(files): implement file storage functionality with save, load, and list operations 2026-03-30 22:24:18 +02:00
79d8219836 feat(metadata): implement streaming response handling and enhance error management for metadata extraction 2026-03-30 21:42:17 +02:00
Hein
2bca9791cb feat(config): add timeout configuration for metadata extraction 2026-03-27 16:01:02 +02:00
4f3d027f9e feat(config): update fallback model handling to support multiple models 2026-03-27 00:44:51 +02:00
8775c3e4ce feat(metadata): enhance metadata extraction with heuristic fallback support 2026-03-27 00:31:30 +02:00
f76d1bbd23 feat(metadata): enhance metadata extraction with reasoning content support 2026-03-27 00:24:16 +02:00
74e67526d1 feat(config): add log_conversations option to AI metadata configuration 2026-03-27 00:12:33 +02:00
6af02a2ba1 feat(metadata): add stripThinkingBlocks function and related tests 2026-03-27 00:05:41 +02:00
a5c7b90f49 feat(config): add fallback model support for AI configurations 2026-03-26 23:54:15 +02:00
0eb6ac7ee5 feat(tools): add maintenance and meal planning tools with CRUD operations
- Implement maintenance tool for adding, logging, and retrieving tasks
- Create meals tool for managing recipes, meal plans, and shopping lists
- Introduce reparse metadata tool for updating thought metadata
- Add household knowledge, home maintenance, family calendar, meal planning, and professional CRM database migrations
- Grant necessary permissions for new database tables
2026-03-26 23:29:03 +02:00
b74d63c543 feat(prompts): add new templates for memory migration and weekly review 2026-03-26 23:08:16 +02:00
eefa78d011 feat(ui): add action links to home page for navigation 2026-03-26 22:49:32 +02:00
f4ef0e9163 feat(backfill): implement backfill tool for generating missing embeddings 2026-03-26 22:45:28 +02:00
1dde7f233d feat(auth): add additional OAuth endpoints and improve client ID handling 2026-03-26 22:30:23 +02:00
56c84df342 feat(auth): implement OAuth 2.0 authorization code flow and dynamic client registration
- Add OAuth 2.0 support with authorization code flow and dynamic client registration.
- Introduce new handlers for OAuth metadata, client registration, authorization, and token issuance.
- Enhance authentication middleware to support OAuth client credentials.
- Create in-memory stores for authorization codes and tokens.
- Update configuration to include OAuth client details.
- Ensure validation checks for OAuth clients in the configuration.
2026-03-26 21:17:55 +02:00
Hein
ed05d390b7 feat(auth): enhance middleware to support Bearer token auth
* Added support for extracting Bearer tokens from Authorization header.
* Updated middleware to prefer explicit header over Bearer token.
* Improved test coverage for authentication scenarios.
2026-03-26 17:02:38 +02:00
Hein
ef0ace2bab chore(docker): remove 'llm' from .dockerignore 2026-03-26 16:32:39 +02:00
Hein
5d43228c2e chore(docker): update environment variable prefixes to AMCS 2026-03-26 16:26:15 +02:00
Hein
8d0a91a961 feat(llm): add LLM integration instructions and handler
* Serve LLM instructions at `/llm`
* Include markdown content for memory instructions
* Update README with LLM integration details
* Add tests for LLM instructions handler
* Modify database migrations to use GUIDs for thoughts and projects
2026-03-25 18:02:42 +02:00
Hein
cebef3a07c feat(embeddings): add embedding model support and related changes
* Introduced EmbeddingModel method in Client and Provider interfaces
* Updated InsertThought and SearchThoughts methods to handle embedding models
* Created embeddings table and updated match_thoughts function for model filtering
* Removed embedding column from thoughts table
* Adjusted permissions for new embeddings table
2026-03-25 16:25:41 +02:00
Hein
c8ca272b03 feat(ai): add support for Ollama AI provider configuration
* Update README with Ollama integration details
* Add Ollama configuration to example YAML files
* Implement Ollama provider in AI factory
* Add tests for Ollama provider functionality
* Enhance config validation for Ollama settings
2026-03-25 12:26:31 +02:00