Commit Graph

1452 Commits

Author SHA1 Message Date
marko-kraemer 77d2d04a03 fix granular tool 2025-10-09 17:17:17 +02:00
marko-kraemer 27c211f1be refactor: major tool system overhaul and cleanup
- Remove deprecated tools (computer_use, deploy, templates, web_dev)
- Migrate all tools to new auto-discovery system
- Remove old tool grouping infrastructure
- Clean up frontend examples and configuration components
- Add tool discovery utilities and documentation
- Simplify agent configuration dialog
- Update dashboard with new AI worker templates
- Net removal of ~5,000 lines of code
2025-10-09 16:54:42 +02:00
marko-kraemer 4dfb171ef8 rem legacy browser tool, switch browser tool to correct one 2025-10-09 16:53:10 +02:00
Krishav 7cfde7f2fc
Merge branch 'kortix-ai:main' into main 2025-10-09 16:27:05 +05:30
Krishav Raj Singh 5ea69c1980 ui: validate slide 2025-10-09 16:26:50 +05:30
Krishav Raj Singh cf6c6142c5 validate ppt 2025-10-09 16:26:50 +05:30
Saumya 7693de456c show paginated details in admin dialog 2025-10-09 16:07:23 +05:30
Saumya 014e6cf222 add variables in trigger prompt 2025-10-09 13:59:40 +05:30
Krishav Raj Singh e129709d96 Revert "fiix: get usage info in case of tool"
This reverts commit 90ee3585cb.
2025-10-09 03:52:48 +05:30
Krishav Raj Singh 90ee3585cb fiix: get usage info in case of tool 2025-10-09 01:25:34 +05:30
Krishav Raj Singh c9c07c4860 update sandbox 2025-10-08 15:34:06 +05:30
Krishav Raj Singh 9a2ae7e09a fix: check healthy when init 2025-10-08 15:33:26 +05:30
Krishav Raj Singh a5d8edabc9 rm image from context 2025-10-08 07:42:49 +05:30
Krishav ae04dddf65
Merge pull request #1785 from KrishavRajSingh/main
remove fallback info
2025-10-08 00:54:28 +05:30
Krishav Raj Singh c7e8a9585d remove fallback info 2025-10-08 00:53:32 +05:30
Saumya 6a7999211b fix: remove pagination for kortix templates 2025-10-07 23:42:23 +05:30
Krishav Raj Singh 6baba64271 fix: typo 2025-10-07 21:14:20 +05:30
Krishav Raj Singh 15e073a5df fix: fallback to anthropic when rate limited by bedrock 2025-10-07 20:52:31 +05:30
Saumya ae81e8e403 fix: model preservation during update 2025-10-07 16:05:02 +05:30
Saumya 89a4996dfd fix: fix agent trigger installation 2025-10-07 15:33:44 +05:30
Saumya 44bd6470c0 fix: add model name for triggers 2025-10-06 23:30:16 +05:30
Saumya 9aad9f3014 add agent usage examples to preview dialog 2025-10-06 16:43:48 +05:30
marko-kraemer f0f14de35a refactor: move URL construction to frontend 2025-10-05 18:33:30 +02:00
marko-kraemer ddf2d32f59 feat(admin): add user thread viewer with admin access bypass
 Features:
- Add admin portal thread viewer with pagination
- Display thread list with project names and public status
- Add clickable links to view threads via /share/{thread_id}
- Add admin bypass for accessing all threads (public and private)

🔧 Backend Refactoring:
- Consolidate admin APIs into admin_api.py and billing_admin_api.py
- Remove unused files: users_admin.py, admin/api.py
- Remove unused endpoints: user search, grant-bulk-credits, migrate-user
- Update admin thread endpoint to use share URLs

 Performance:
- Remove message_count from UserThreadSummary (optimization)
- Remove N+1 query issue in thread listing

🔒 Authorization:
- Add admin role bypass in verify_and_authorize_thread_access
- Create RLS migration (20251005160000_admin_roles_access.sql)
- Update thread_select_policy for admin access
- Update message_select_policy for admin access
- Update project_select_policy for admin access
- Update agent_runs_select_policy for admin access

💻 Frontend:
- Add Threads tab to admin user details dialog
- Add useAdminUserThreads hook with pagination
- Remove unused admin hooks (useAdminUserSearch, useAdminAdvancedSearch)
- Display thread metadata with Open button and ExternalLink icon

🗃️ Database:
- Apply RLS policies allowing admin/super_admin roles to bypass restrictions
- Admins can now view any thread, message, project, or agent_run

This enables admins to view and debug any user's threads through the
share page interface, regardless of public/private status.
2025-10-05 18:09:26 +02:00
Marko Kraemer 7f89d96b45
Merge pull request #1777 from kortix-ai/refactor/simplify-backend-agent-handling
Remove workflows system; refactor/simplify backend agent handling
2025-10-04 17:56:08 -07:00
marko-kraemer 0c9c78ec40 wip 2025-10-05 02:55:08 +02:00
marko-kraemer 0ec17b0d3a refactor: completely remove workflow and playbook system
- Remove workflow_tool.py and all workflow-related backend code
- Delete all workflow database tables and create migration
- Remove workflow API endpoints and execution logic
- Clean workflow references from agent tools and triggers
- Remove playbooks tab and UI from agent configuration
- Eliminate workflow_id, workflow_input, and execution_type fields
- Simplify trigger system to agent-only execution
- Remove workflow tool definitions from tool registry
- Clean up TypeScript interfaces and remove workflow types
- Remove playbooks button from chat input
- Update all trigger components to remove workflow selection
- Clean workflow metadata from threads and sidebar
- Remove 80+ critical workflow code references

Simplifies codebase by eliminating complex dual-mode (agent/workflow)
execution system in favor of pure agent-based automation.
2025-10-05 01:51:44 +02:00
Krishav Raj Singh f11d612094 fix: update litellm 2025-10-05 05:17:54 +05:30
Krishav Raj Singh 64a1e9a2aa Revert "hotfix: compression"
This reverts commit 6dad29b3dd.
2025-10-05 05:16:43 +05:30
marko-kraemer c62ea28237 refactor: remove deprecated code and endpoints
- Removed deprecated GET /agent-runs/{agent_run_id} endpoint from threads.py (20 lines)
- Removed unimplemented delete_mcp_server() method from mcp_server_service.py (12 lines)
- Removed deprecated 'sync' and 'update-all' commands from manage_suna_agents.py script (9 lines)
- Cleaned up 41 lines of dead/deprecated code
- No functional impact as these were already marked deprecated or non-functional
2025-10-04 22:45:41 +02:00
marko-kraemer 8b7bc36d5f refactor: consolidate duplicate account lookup logic
- Extracted get_account_id_from_thread() to auth_utils.py (new shared utility)
- Refactored 2 identical _get_current_account_id() methods:
  * tools/agent_builder_tools/base_tool.py (reduced 23 lines → 9 lines)
  * tools/sb_upload_file_tool.py (reduced 23 lines → 9 lines)
- Simplified agent_creation_tool.py's version for consistency
- Eliminated 28+ lines of duplicate code
- Centralized thread→account lookup logic in one place
2025-10-04 22:45:09 +02:00
marko-kraemer 5383897977 refactor: remove redundant code - eliminate 7 workspace_path duplications
- Removed redundant workspace_path='/workspace' from 7 sandbox tool files
  * sb_files_tool.py
  * sb_shell_tool.py
  * sb_deploy_tool.py
  * sb_templates_tool.py
  * sb_upload_file_tool.py
  * sb_presentation_tool.py
  * sb_web_dev_tool.py

- Base class SandboxToolsBase already sets this on line 23
- Eliminates 7 lines of duplicate code
- All tools now inherit workspace_path from base

- Converted sb_upload_file_tool.py to use centralized db_helpers
  * Removed DBConnection import
  * Uses get_initialized_db() instead
2025-10-04 22:43:46 +02:00
marko-kraemer 98e9196d41 refactor: simplify backend - fix naming conflicts and centralize DB dependencies
Backend improvements:
- Fixed duplicate TemplateService naming conflict:
  * Renamed marketplace_service.py::TemplateService → MarketplaceService
  * Eliminates confusion between two classes with same name

- Created centralized DB dependency helpers (db_helpers.py):
  * get_db() - FastAPI dependency for DB connection (singleton)
  * get_db_client() - Returns initialized Supabase client
  * get_initialized_db() - For module-level backward compatibility
  * Addresses 100+ DBConnection() instantiations across 53 files

- Applied new DB helpers to high-usage files:
  * services/api_keys_api.py - Now uses get_db() dependency
  * templates/services/marketplace_service.py - Uses get_initialized_db()

- Comprehensive simplification analysis document:
  * Identified 9 modules with duplicate initialize() patterns
  * Documented large files needing breakdown (1700-2000 lines)
  * Analyzed 35 tool files for common patterns
  * Prioritized recommendations for future work

Frontend cleanup:
- Removed unused template preview components and pages
2025-10-04 22:40:16 +02:00
marko-kraemer 8d7e85de4c refactor: massive backend simplification - eliminate 450+ lines of duplicate code
- Created unified AgentLoader for all agent data operations
- Eliminated 8 manual AgentResponse constructions across codebase
- Reduced agent_runs.py complexity by 163 lines (85→35 lines in 2 functions)
- Reduced core_utils.py from 553→69 lines (-87%)
- Extracted focused utility modules:
  * utils/icon_generator.py (179 lines)
  * utils/limits_checker.py (245 lines)
  * utils/run_management.py (145 lines)
  * utils/project_helpers.py (113 lines)
  * utils/mcp_helpers.py (41 lines)
- Fixed duplicate router inclusions in api.py
- Renamed template_service.py → marketplace_service.py for clarity
- Reduced template transformer from 73→17 lines (-77%)
- Inlined module-specific helpers (moved agent_run access check)
- Fixed version data false alarm warnings
- Updated AgentResponse model to support optional fields for list operations

Total impact: ~450 lines of duplicate code eliminated, dramatically improved maintainability
2025-10-04 22:32:51 +02:00
Krishav Raj Singh 6dad29b3dd hotfix: compression 2025-10-05 00:47:47 +05:30
Saumya 550b9f42ce Merge branch 'main' of https://github.com/kortix-ai/suna into fix-ui-bugs 2025-10-04 03:06:43 +05:30
Saumya 056150059f fix usage deduction 2025-10-04 03:05:54 +05:30
Saumya 381081964f fix billing calculation 2025-10-03 23:18:07 +05:30
Krishav Raj Singh 6d208ef7f3 fix: present_presentation in ppt grp 2025-10-03 21:50:07 +05:30
marko-kraemer 85c4ae00e7 Remove usage_example decorator and all usages 2025-10-03 12:24:36 +02:00
Saumya faf1114c8f Merge branch 'main' of https://github.com/kortix-ai/suna into fix-ui-bugs 2025-10-03 14:58:37 +05:30
marko-kraemer 31c0f8b348 registry fix 2025-10-03 11:10:01 +02:00
Saumya c00bc82b2b Merge branch 'main' of https://github.com/kortix-ai/suna into fix-ui-bugs 2025-10-02 21:51:07 +05:30
Krishav Raj Singh 5c08628394 update description 2025-10-02 15:39:52 +05:30
Krishav Raj Singh ca94a759a9 compress and omit if exceeds context window 2025-10-02 15:05:59 +05:30
Saumya 6f02f398d3 Merge branch 'main' into fix-ui-bugs 2025-10-02 00:36:03 +05:30
Bobbie 7ff206157d
Merge pull request #1767 from escapade-mckv/prebuilt-agents
Prebuilt agents
2025-10-01 22:58:31 +05:30
marko-kraemer e0250092a6 temp reg anthropic 2025-10-01 17:05:03 +02:00
marko-kraemer 6f467c35c0 1m ctxt bedrock 2025-10-01 15:44:02 +02:00
Saumya ccbfe7d975 Merge branch 'main' of https://github.com/kortix-ai/suna into prebuilt-agents 2025-10-01 12:19:15 +05:30