Skip to main content

max / everycycle

1.7 KB · 45 lines History Blame Raw
1 #![allow(clippy::doc_markdown)]
2
3 //! Native EveryCycle client API.
4 //!
5 //! The stable surface every first-party client and every Thread J
6 //! compatibility shim writes against. Pre-v1 every release may
7 //! break; once `API_VERSION` reads `"1"`, semver applies per
8 //! `docs/api-stability.md`.
9 //!
10 //! This crate is types and traits only. The daemon-side server and
11 //! the client transports live in their own crates. The intent is
12 //! that the C ABI module boundary discussed in the roadmap
13 //! ("Implementation languages") falls along this crate's public
14 //! types — so when the second-language client lands, the
15 //! translation is mechanical.
16 //!
17 //! # Design
18 //!
19 //! The component layout and executor model are in `docs/architecture.md`; the
20 //! ecosystem view and the tinygrad pairing live in the maintainer wiki.
21 //! <!-- wiki: everycycle-overview -->
22
23 pub mod event;
24 pub mod model;
25 pub mod request;
26 pub mod transport;
27
28 pub use event::{ErrorKind, ExecutorSummary, FleetSnapshot, LoadedModel, ServerEvent, TokenChunk};
29 pub use model::{ChatMessage, ChatRole, ModelRef, Priority, PromptSpec, SamplingParams};
30 pub use request::{ClientRequest, InferenceRequest, RequestId, RequestKind};
31 pub use transport::{
32 ClientTransport, EventStream, FRAME_LENGTH_BYTES, MAX_FRAME_BYTES, TransportError,
33 default_socket_path,
34 };
35
36 /// Wire-format version. Pre-1.0 every release may break this
37 /// surface; from `"1"` onward the rules in `docs/api-stability.md`
38 /// apply.
39 pub const API_VERSION: &str = "0";
40
41 /// True until the v1 freeze gate trips. Clients should refuse to
42 /// connect to a daemon advertising a different stability state
43 /// than they were built against.
44 pub const API_UNSTABLE: bool = true;
45