Currently, the Cortex skills system stores AI capabilities as single database rows (e.g., system_prompt, preview_markdown, config). The UI consists of large text areas where users paste monolithic prompts containing all custom scripts and reference data.
Shortcomings:
system_prompt exhausts the LLM’s context window limit and degrades reasoning capabilities.Our research confirms that the industry standard has moved away from monolithic prompting:
execute and execute_ipython_shell actions. Global skills and repository guidelines are stored as markdown files (like AGENTS.md) and python scripts within the workspace, which are read/executed only when triggered, rather than injected into the system prompt upfront./mnt/data/ within the sandbox. The LLM writes small wrapper scripts to execute or read these files dynamically.The skill definition paradigm must shift from database forms to file trees. A skill should represent a containerized environment of rules, references, and executable assets.
A given skill (e.g., mesh-file-explorer) would be managed just like a Git repository folder containing:
/skills/mesh-file-explorer/ ├── SKILL.md # Core instructions & meta-rationale (What the LLM reads first) ├── scripts/ # Executable runtimes to lazy load (e.g., node.js CLI tools, Python scrapers) │ ├── run_explorer.py │ └── helper.sh ├── examples/ # Example usages or inputs (few-shot prompting material) │ └── successful_logs.txt └── artifacts/ # Binary plugins or reference files
The primary benefit of this folder structure is Lazy Context Injection.
SKILL.md or a standard system tool describing the folder's purpose.view_skill_artifact or execute_plugin_script. If the LLM determines it needs to run a web scraper, it calls scripts/run_scraper.py.system_prompt) to a virtualized file system mapping. Skills can either be saved to a network drive, synced through the agent-node mesh, or abstracted behind an Object Storage system (S3/minio) or a Virtual File System DB design./skills CRUD with a hierarchy:
GET /skills/:id/tree (Fetch folder hierarchy)GET /skills/:id/files/:path (Read asset contents)POST /skills/:id/files/:path (Upload/Create code scripts inside a skill)The current UI requires replacing the simple forms ("Engineering Mode") with a "Skill Editor Workspace" modeled after basic web-IDEs (like VSCode web or Git repository interfaces).
SKILL.md, scripts/, artifacts/./scripts directory directly into the Agent's sandbox PATH environment variable, making tool invocation native and seamless in bash.Through this refactoring, skills graduate from "Large Prompts" to "Software Packages". This creates an ecosystem where developers can drop in a complex Docker network or Python repository into a skill folder, and the Cortex LLM can dynamically research and execute those resources as needed without breaking context sizes.