ryo-app 0.1.0

[preview] Application layer for RYO - Project management, Intent handling, API
Documentation

ryo-app

crates.io docs.rs License: MIT OR Apache-2.0

Status: preview. Reader API stable, Writer API experimental. Part of the ryo workspace — AST-centric Rust programming for AI agents.

Application layer for ryo: project management (in-memory AST collection with I/O), Intent / Goal (user-intention representation with JSON Schema for LLM integration), Api (the external interface for CLI / UI / Agent), and a Storage trait for dependency injection.

Install

cargo add ryo-app

Optional features: schemars (JSON Schema derive), fuzzy-parser (LLM-typo repair via ryo-fuzzy-parser), literal-search (full-text via tantivy).

Quickstart

use ryo_app::{Api, Project, Goal, Intent, IdentKind, Pattern, InMemoryStorage};

let mut project = Project::from_dir("src/")?;

let storage = Box::new(InMemoryStorage::new());
let mut api = Api::new(storage);

let goal = Goal::new(Intent::RenameIdent {
    from: Pattern::exact("old_name"),
    to: "new_name".to_string(),
    kind: IdentKind::Any,
});

let result = api.execute(&mut project, goal)?;

API Summary

Item Purpose
Api External interface (executor + storage DI)
Project In-memory AST file collection with I/O
Intent / Goal User intention types (JSON-schema-able)
Storage trait + InMemoryStorage / FileUuidStorage Persistence DI
Planner / PlanError Goal planning
DiscoverService / SpecService Reader-side facades
Format / TxLogMode (re-exported from ryo-storage) Storage formats

Status

Preview. Reader-side APIs (DiscoverService, SpecService, queries) are considered stable for v0.1.0. Writer-side APIs (Api::execute against mutation goals) depend on the experimental ryo-executor and may evolve.

License

Licensed under either of Apache-2.0 or MIT at your option.