Expand description
§attuned-core
Core types and traits for Attuned - a Rust framework for representing human state as interpretable vectors and translating them into interaction constraints for LLM systems.
§Overview
Attuned produces context, not actions. It represents user state across interpretable dimensions (axes) and translates that state into guidelines for LLM interactions.
§Core Types
StateSnapshot- A point-in-time capture of user statePromptContext- Translated guidelines for LLM conditioningTranslator- Trait for converting state to context
§Example
use attuned_core::{StateSnapshot, Source, RuleTranslator, Translator};
// Create a state snapshot
let snapshot = StateSnapshot::builder()
.user_id("user_123")
.source(Source::SelfReport)
.axis("warmth", 0.7)
.axis("cognitive_load", 0.9)
.build()
.unwrap();
// Translate to prompt context
let translator = RuleTranslator::default();
let context = translator.to_prompt_context(&snapshot);
// Use guidelines in your LLM system prompt
for guideline in &context.guidelines {
println!("{}", guideline);
}Re-exports§
pub use axes::get_axis;pub use axes::is_valid_axis_name;pub use axes::Axis;pub use axes::AxisCategory;pub use axes::AxisDefinition;pub use axes::DeprecationInfo;pub use axes::CANONICAL_AXES;pub use telemetry::init_tracing;pub use telemetry::init_tracing_from_env;pub use telemetry::AuditEvent;pub use telemetry::AuditEventType;pub use telemetry::ComponentHealth;pub use telemetry::HealthCheck;pub use telemetry::HealthState;pub use telemetry::HealthStatus;pub use telemetry::OtelConfig;pub use telemetry::TelemetryBuilder;pub use telemetry::TelemetryGuard;pub use telemetry::TracingConfig;pub use telemetry::TracingFormat;
Modules§
- axes
- Axis definitions for Attuned state representation.
- telemetry
- Observability infrastructure for Attuned.
Structs§
- Prompt
Context - Context produced by translating user state.
- Rule
Translator - Rule-based translator that converts state to context using threshold rules.
- State
Snapshot - A snapshot of user state at a point in time.
- State
Snapshot Builder - Builder for constructing StateSnapshot instances.
- Thresholds
- Threshold configuration for rule-based translation.
Enums§
- Attuned
Error - Top-level error type for Attuned operations.
- Source
- The source of a state snapshot - how the data was obtained.
- Validation
Error - Validation errors for state data.
- Verbosity
- Output verbosity level for LLM responses.
Traits§
- Translator
- Trait for translating state snapshots to prompt context.