Skip to content

Latest commit

 

History

History
80 lines (56 loc) · 4.83 KB

index.md

File metadata and controls

80 lines (56 loc) · 4.83 KB
description Reference index for apcore subsystems: everyday application developer references (client, modules, governance, observability) and deep framework internals for SDK implementers.

Feature Reference

Complete contract and 3-language (Python, TypeScript, Rust) reference for every apcore subsystem.

!!! tip "New to apcore?" This section is a reference manual — you do not need to read it cover to cover. Start with Getting Started and the task-oriented User Guides, then come back here when you need exact API signatures, config keys, or edge-case behavior. For normative RFC 2119 rules, see the Protocol Specification.

Part 1 — Everyday Reference (Application Developers)

The subsystems most application teams use directly.

Core API & Modules

Primary interfaces for defining, binding, and calling modules.

  • APCore Client — The recommended unified entry point (call, validate, stream, use, discover).
  • Module Interface — The module contract, behavioral annotations, lifecycle hooks, preflight(), and preview().
  • Context Object — Per-invocation trace_id, identity, call_chain, cancel_token, and shared data.
  • Bindings (Decorator/YAML) — Function decorators and zero-code YAML bindings.
  • ID Normalization — Bare-name canonicalization and module-ID validation rules.

Security & Governance

Guardrails, caller identity, permissions, and human-in-the-loop approval.

  • ACL System — Default-deny pattern rules (caller_id → target_id), conditions, and audit logging.
  • Approval System — Human-in-the-loop approval gate, sync/async resume, and ExecutionPolicy.
  • Identity System — Caller representation (id, type, roles, attrs).
  • Call Chain Guard — Depth limits, circular-call detection, and repeat-frequency protection.
  • ACL-aware Capability Discovery — Caller-scoped module summaries and schema lookup.

Execution & Workflow

How calls run, stream, execute in the background, or cancel.

Reliability & Observability

Tracing, metrics, redaction, structured errors, events, and runtime introspection.

  • Observability — W3C tracing, spans, sampling, exporters, and ContextLogger.
  • Redaction — Automatic redaction of x-sensitive fields and configured secret patterns.
  • Error & AI Guidance — Error codes and recovery fields (retryable, user_fixable, ai_guidance).
  • Metrics & Usage — Call counters, latency histograms, Prometheus rendering, and usage tracking.
  • Error History — Recent-error aggregation for introspection.
  • Event System — Framework-wide async event bus and subscribers.
  • System Modules (system.*) — Built-in health, manifest, usage, and runtime control modules.

Part 2 — Framework Internals (Advanced & SDK Implementers)

Lower-level infrastructure for custom extensions, multi-package hosting, and SDK authors.

  • Registry System — Discovery, registration, dependency ordering, and hot-reload draining.
  • Schema System — JSON Schema Draft 2020-12 loading, $ref resolution, and validation.
  • Middleware System — Onion execution model, built-in middleware, and step middleware.
  • Extension Points — Replacing discoverers, validators, ACL, and approval handlers.
  • Config Bus — Unified multi-package YAML configuration and env-var binding.
  • Multi-Module Discovery — Opt-in multi-class file scanning.
  • Artifact References — Opaque artifact metadata and bounded host reads.

For the high-level mental model, see Core Concepts or Architecture Design.