Skip to content

feat: wire 23 extended AI tools into system#11

Open
coder-contrib-bot wants to merge 1 commit into
mainfrom
claude-code/wire-extended-tools/k7m2p9x4
Open

feat: wire 23 extended AI tools into system#11
coder-contrib-bot wants to merge 1 commit into
mainfrom
claude-code/wire-extended-tools/k7m2p9x4

Conversation

@coder-contrib-bot
Copy link
Copy Markdown
Collaborator

Summary\n\nWires the 23 extended tools (created in extended_tools.py) into the full AI pipeline so Claude can actually discover and execute them.\n\n### Changes:\n\n**backend/app/ai/tools/tool_schemas.py\n- Added 23 new tool schemas for: opening balances (5), expenses (3), sales invoice retrieval (4), purchase invoices (5), suppliers (3), products (3)\n- Claude reads these schemas to know what tools are available\n\nbackend/app/ai/executor.py\n- Added ExtendedTools import and instantiation\n- Added all 23 new lambda mappings in _build_tool_map()\n- Added new financial tools to FINANCIAL_TOOLS dict (create_expense, create_purchase_invoice, all opening balance tools)\n- Added memory storage for purchase invoices and expenses\n\nbackend/app/ai/safety/permissions.py\n- Added all new tools to manager, cashier, warehouse_employee, accountant, and ai_agent role configs\n- Each role gets appropriate read/write access based on responsibility\n\nbackend/app/ai/safety/transaction_guard.py\n- Added 9 new write operations to SENSITIVE_OPERATIONS set\n- Added confirmation thresholds for all new sensitive operations\n- Added Arabic descriptions for all new operations in _describe_operation()\n- Added dry-run preview support for new operations\n- Added rollback support for purchase invoices\n\nbackend/app/routers/ai_audit.py\n- Added all 23 new tools to TOOL_CATEGORIES with Arabic category names\n- Added Arabic labels for all new tools in _tool_label()\n- Added execution descriptions for all new tools in _describe_execution()\n\n### AI Agent Capabilities After This PR:\n- Set opening balances (customer, supplier, cash, inventory)\n- Create and list expenses\n- Retrieve and inspect sales/purchase invoices with line items\n- Create sales and purchase returns\n- Create purchase invoices\n- Manage suppliers (create, update, search)\n- Manage products (create, update, get details)\n\n---\n\nAuthor:** Claude Code (AI Agent)\nEmail: claude-code@anthropic.com\n\n🤖 Generated with Claude Code"}

…rd, and audit

- Add 23 new tool schemas to tool_schemas.py for Claude discovery
- Add ExtendedTools import and all mappings in executor._build_tool_map()
- Add new financial tools to FINANCIAL_TOOLS dict
- Add new tools to all role permission lists in permissions.py
- Add new sensitive write operations to transaction_guard.py
- Add new tool categories and Arabic labels to ai_audit.py

GIT_AUTHOR_NAME: Claude Code (AI Agent)
GIT_AUTHOR_EMAIL: claude-code@anthropic.com

Co-Authored-By: Claude Code <claude-code@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant