Expand description
oino-resources: resource loading for Oino — context files (AGENTS.md & co.),
SYSTEM/APPEND prompt sources, skills, prompt templates, theme files, the structured system
prompt, project trust and the keybindings file.
Boundary: synchronous std I/O, no async runtime; oino-core calls it on blocking threads.
Packages and extensions are resolved by oino-core and contribute paths through
ResourceLoader::extend.
§API map
| Module | Contents |
|—|—|—|
| loader | ResourceLoader, ResourceLoaderOptions, ResourceExtensionPaths, ThemeResource |
| discovery | settings arrays + auto-discovery with !glob/+path/-path, precedence |
| context_files | ContextFile, context_files::load_project_context_files |
| system_prompt | BuildSystemPromptOptions, SystemPromptState, system_prompt::build_system_prompt_sections, system_prompt::build_system_prompt_state, system_prompt::diff_system_prompt_sections |
| skills | Skill, skills::load_skills, skills::format_skills_for_prompt, skills::expand_skill_command |
| templates | PromptTemplate, templates::parse_command_args, templates::substitute_args, templates::expand_prompt_template |
| trust | trust::TrustStore, trust::has_protected_resources, trust::resolve_project_trust |
| keybindings | keybindings::KeybindingsFile, keybindings::migrate_keybindings_config, keybindings::is_valid_key_id |
| frontmatter | frontmatter::parse_frontmatter |
| diagnostics, source | diagnostics.ts, source-info.ts | ResourceDiagnostic, SourceInfo, source::PathMetadata |
Product substitutions (D13): the default preamble names Oino, the docs section points at the
bundled Oino docs (docs_root), and the bash env guideline is system_prompt::ENV_GUIDELINE.
Re-exports§
pub use context_files::ContextFile;pub use diagnostics::DiagnosticKind;pub use diagnostics::ResourceDiagnostic;pub use loader::ExtraResourcePath;pub use loader::ResourceExtensionPaths;pub use loader::ResourceLoader;pub use loader::ResourceLoaderOptions;pub use loader::ThemeResource;pub use skills::Skill;pub use source::SourceInfo;pub use system_prompt::BuildSystemPromptOptions;pub use system_prompt::SystemPromptState;pub use templates::PromptTemplate;
Modules§
- context_
files - Project context files (runtime §9.2).
- diagnostics
- Resource diagnostics.
- discovery
- Local resource resolution (minus packages): settings
resource arrays of both scopes plus auto-discovered directories, with
!glob,+path,-pathoverrides and precedence ordering. - frontmatter
- YAML frontmatter.
- keybindings
<agent>/keybindings.json: load, migrate legacy names, validate key ids. Semantics (defaults, conflicts, dispatch) belong to frontends.- loader
ResourceLoader(minus extension loading): skills, prompt templates, theme files, context files and SYSTEM/APPEND prompt sources.- skills
- Skills: discovery, frontmatter validation, prompt formatting and
/skill:nameexpansion. - source
- Resource provenance (
source-info,PathMetadata). - system_
prompt - Structured system prompt with the D13 product substitutions of runtime §9.4.
- templates
- Prompt templates: loading, argument parsing and
substitution,
/name argsexpansion. - trust
- Project trust (runtime §9.7).