ebbmem_client_generated/models/graph_node.rs
1/*
2 * Ebb Memory Engine API
3 *
4 * Production cognitive memory engine and multi-transport gateway for autonomous AI agents. Features continuous mass-dilated logarithmic decay, Hebbian co-activation networks, off-heap mmap storage, and unified enterprise security. Canonical public HTTP contract for Ebb client SDKs. Generated from the hosted FastAPI application. Excludes internal and admin routes (`/api/v1/admin/_**`, `/metrics`, `/mcp`). Protected operations require `Authorization: Bearer <token>` (security scheme `HTTPBearer`). The same routes accept an optional `X-API-Key` header and `X-Ebb-Namespace` to select a namespace. Error responses use the `ErrorResponse` envelope (`code`, `message`, `details`) plus FastAPI's `HTTPValidationError` for 422. SDK subset of the Ebb HTTP contract. Includes Memory, Tasks, Events, and Health. Omits admin, runtime config, provider probes, registration, password reset, and SSO.
5 *
6 * The version of the OpenAPI document: 0.2.0
7 * Contact: maintainers@spectrayan.com
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14/// GraphNode : Graph node representing a memory engram.
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct GraphNode {
17 #[serde(rename = "id")]
18 pub id: String,
19 #[serde(rename = "tier", skip_serializing_if = "Option::is_none")]
20 pub tier: Option<String>,
21 #[serde(rename = "text_preview", skip_serializing_if = "Option::is_none")]
22 pub text_preview: Option<String>,
23 #[serde(rename = "importance", skip_serializing_if = "Option::is_none")]
24 pub importance: Option<f64>,
25 #[serde(rename = "valence", skip_serializing_if = "Option::is_none")]
26 pub valence: Option<i32>,
27 #[serde(rename = "arousal", skip_serializing_if = "Option::is_none")]
28 pub arousal: Option<i32>,
29 #[serde(rename = "timestamp_ms", skip_serializing_if = "Option::is_none")]
30 pub timestamp_ms: Option<i32>,
31 #[serde(rename = "tags", skip_serializing_if = "Option::is_none")]
32 pub tags: Option<Vec<String>>,
33}
34
35impl GraphNode {
36 /// Graph node representing a memory engram.
37 pub fn new(id: String) -> GraphNode {
38 GraphNode {
39 id,
40 tier: None,
41 text_preview: None,
42 importance: None,
43 valence: None,
44 arousal: None,
45 timestamp_ms: None,
46 tags: None,
47 }
48 }
49}
50