build(agent): new-agents-4#58ba63 iteration
This commit is contained in:
parent
4388247d56
commit
7ece74b55e
|
|
@ -10,3 +10,18 @@ void EnergiBridge_map_LocalMarket_to_CatOpt(const LocalMarket* lm, CatOpt_Object
|
|||
// Best-effort: initialize a simple static version; in a real system this would be a per-message counter
|
||||
out->version = 1;
|
||||
}
|
||||
|
||||
void EnergiBridge_map_SharedSignals_to_CatOpt(const SharedSignals* ss, CatOpt_Signal* out) {
|
||||
if (!ss || !out) return;
|
||||
out->aggregated_greeks = ss->aggregated_greeks;
|
||||
out->implied_vol = ss->implied_vol;
|
||||
out->version = 1;
|
||||
}
|
||||
|
||||
void EnergiBridge_map_PlanDelta_to_CatOpt(const PlanDelta* pd, CatOpt_PlanDelta* out) {
|
||||
if (!pd || !out) return;
|
||||
out->quote = pd->quote;
|
||||
out->hedge = pd->hedge;
|
||||
out->timestamp = pd->timestamp;
|
||||
out->version = 1;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -35,4 +35,10 @@ typedef struct CatOpt_PlanDelta {
|
|||
// Map a LocalMarket instance to a CatOpt_Object. This is intentionally simple and side-effect free.
|
||||
void EnergiBridge_map_LocalMarket_to_CatOpt(const LocalMarket* lm, CatOpt_Object* out);
|
||||
|
||||
// Map SharedSignals to a CatOpt_Signal.
|
||||
void EnergiBridge_map_SharedSignals_to_CatOpt(const SharedSignals* ss, CatOpt_Signal* out);
|
||||
|
||||
// Map PlanDelta to a CatOpt_PlanDelta (with version for conformance).
|
||||
void EnergiBridge_map_PlanDelta_to_CatOpt(const PlanDelta* pd, CatOpt_PlanDelta* out);
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Binary file not shown.
|
|
@ -3,8 +3,8 @@ CFLAGS := -Wall -Wextra -O2
|
|||
|
||||
all: delta_mesh_demo
|
||||
|
||||
delta_mesh_demo: demo_main.o admm_lite.o LocalMarket.o SharedSignals.o PlanDelta.o
|
||||
$(CC) $(CFLAGS) -o delta_mesh_demo/demo delta_mesh/demo_main.o delta_mesh/admm_lite.o delta_mesh/LocalMarket.o delta_mesh/SharedSignals.o delta_mesh/PlanDelta.o
|
||||
delta_mesh_demo: demo_main.o admm_lite.o LocalMarket.o SharedSignals.o PlanDelta.o dsl_seed.o
|
||||
$(CC) $(CFLAGS) -o delta_mesh_demo/demo delta_mesh/demo_main.o delta_mesh/admm_lite.o delta_mesh/LocalMarket.o delta_mesh/SharedSignals.o delta_mesh/PlanDelta.o delta_mesh/dsl_seed.o
|
||||
|
||||
%.o: %.c
|
||||
$(CC) $(CFLAGS) -c $< -o $@
|
||||
|
|
|
|||
BIN
delta_mesh/demo
BIN
delta_mesh/demo
Binary file not shown.
|
|
@ -0,0 +1,11 @@
|
|||
// Minimal DSL seed implementation for DeltaMesh MVP (toy).
|
||||
#include "dsl_seed.h"
|
||||
#include <stdio.h>
|
||||
|
||||
// Example entry point to exercise the seed artifacts without pulling external deps.
|
||||
void dsl_seed_example_log(void) {
|
||||
AuditLog log = { "delta_seed_initialized", 0 };
|
||||
(void)log; // suppress unused warning in a tiny demo
|
||||
// No-op print guarded by a macro in a real build; kept tiny to avoid side effects.
|
||||
// printf("%s @ %lu\n", log.entry, log.timestamp);
|
||||
}
|
||||
|
|
@ -0,0 +1,24 @@
|
|||
// Minimal DSL seed primitives for DeltaMesh MVP (toy).
|
||||
// This header provides lightweight, forward-looking data structures that
|
||||
// can be used by adapters and the coordination layer to agree on contract
|
||||
// representations without leaking raw data.
|
||||
|
||||
#ifndef DSL_SEED_H
|
||||
#define DSL_SEED_H
|
||||
|
||||
typedef struct LocalArbProblem {
|
||||
double objective; // toy objective value for the arb problem
|
||||
unsigned long timestamp; // monotonic timestamp for replay
|
||||
} LocalArbProblem;
|
||||
|
||||
typedef struct AuditLog {
|
||||
const char* entry; // human-readable log entry or hash
|
||||
unsigned long timestamp; // log timestamp for replay and audit
|
||||
} AuditLog;
|
||||
|
||||
typedef struct GovernanceBlock {
|
||||
const char* policy; // description of governance constraint
|
||||
unsigned long timestamp; // policy versioning / timestamp
|
||||
} GovernanceBlock;
|
||||
|
||||
#endif
|
||||
Loading…
Reference in New Issue