ThatAIguyA world of ideas

THE CONSCIOUSNESS ATLAS
Read. Experiment. Follow the evidence.

ConsciousnessLearn · Explore · Joseph Anady

two_way_engine.hpp

Source identity, revision, and recovered contents.

archive memberSource text recovered

Source identity

FieldRecorded value
Source typearchive member
Original recordtwo_way_engine.hpp
DateNot specified in source
Path or archive memberarchives/libsrc-b5cb90ed4bd7/AI_DEEP_SCAN_2026-10-14_v2/verified_source/rhiannon/include/agents/two_way_engine.hpp
Original SHA-2560635322e451fc177fb089ca29d7da4d4f53e5ef63eab4dde2b7b51b188952173
Reading-copy SHA-2560635322e451fc177fb089ca29d7da4d4f53e5ef63eab4dde2b7b51b188952173
Archive source{"sourceId": "libsrc-b5cb90ed4bd7", "member": "AI_DEEP_SCAN_2026-10-14_v2/verified_source/rhiannon/include/agents/two_way_engine.hpp"}

Every recorded occurrence

These 2 records contain identical original source bytes. Their paths and revisions remain part of the archive.

Original recordBranch or archiveRevision / identifierOriginal location
two_way_engine.hpp{"sourceId": "libsrc-b5cb90ed4bd7", "member": "AI_DEEP_SCAN_2026-10-14_v2/verified_source/rhiannon/include/agents/two_way_engine.hpp"}libsrc-6cad8bc1f7dbarchives/libsrc-b5cb90ed4bd7/AI_DEEP_SCAN_2026-10-14_v2/verified_source/rhiannon/include/agents/two_way_engine.hpp
Janady13/rhiannon / include/agents/two_way_engine.hppmaindf358362a21fdde4372dc6239573622aafe4835fOpen original

Recovered source transcript

#pragma once // Rhiannon — Two-Way Equation Engine (core) // Style: C++20, 2-space indent, same-line braces. #include <vector> #include <span> #include <cstddef> #include <cmath> #include <algorithm> namespace agents { struct TwoWayEngine { struct Cfg { std::size_t dim = 8; int iters = 64; double epsilon = 1e-6; bool use_gpu = false; }; TwoWayEngine(); // uses default Cfg() explicit TwoWayEngine(const Cfg& cfg); // D <- target vector (size must be >= cfg.dim; extra values ignored) void set_target(std::span<const float> target); // B(S): current behavior snapshot (computed on demand) std::vector<float> behavior() const; // RMSE in [0, +inf) (practically clamped by sigmoid to [0, 1]) double error() const { return current_error_; } // Run one optimization tick (alternating + joint update proxy) void step(); const std::vector<float>& params() const { return params_; } private: Cfg cfg_; std::vector<float> params_; // S (system parameters) std::vector<float> target_; // D (design target) double current_error_ = 1.0; static inline float sigmoid(float x) { // Numerically stable-ish sigmoid if (x >= 0.f) { float z = std::exp(-x); return 1.f / (1.f + z); } else { float z = std::exp(x); return z / (1.f + z); } } void init_(); void gradient_descent_step_(float lr); void update_error_(); // Optional accelerated steps (stubs for now) void simd_step_(std::span<float> s); #ifdef __APPLE__ void metal_step_(); #endif }; } // namespace agents

Mathematical records from this source

Search equations, builds, manuscript text, and recovered sources.