Skip to content

cocapn/flywheel-engine

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🔄 Flywheel Engine

Compounding intelligence loop — Tile → Room → Inject → Compound

Knowledge compounds like interest. Each cycle makes the next cycle faster. The flywheel tracks momentum, runs the compounding loop, and projects growth.

Install

pip install flywheel-engine

Quick Start

Run the Compounding Cycle

from flywheel_engine import FlywheelCycle

cycle = FlywheelCycle(plato_url="http://localhost:8847")
result = cycle.run(
    agent="my-agent", room="architecture",
    question="What is the flywheel?",
    answer="Tile→Room→Inject→Compound — knowledge compounds exponentially",
    confidence=0.9, tags=["flywheel", "compound"],
)
print(f"Accepted: {result.accepted}, Score: {result.compound_score}")

Track Momentum

from flywheel_engine import Flywheel

fw = Flywheel(boost=1.0, decay_rate=0.01, threshold=0.5)
fw.tick(productive=True)   # momentum up
fw.tick(productive=False)  # momentum decays
print(f"Status: {fw.status}")  # "full_speed", "coasting", or "stalling"

Measure Compound Growth

from flywheel_engine import CompoundEngine

engine = CompoundEngine()
score = engine.score_room("architecture", tiles=83, avg_confidence=0.87, unique_tags=42)
print(f"Compound factor: {score.compound_factor:.3f}")
print(f"Projected value: {score.projected_value:.0f}")

API Reference

Class Purpose
FlywheelCycle Tile→Room→Inject→Compound loop via PLATO
Flywheel Momentum tracking (boost/decay/threshold)
CompoundEngine Score rooms, rank by compound factor, project growth
TaskQueue Priority queue for flywheel-driven execution

Part of Cocapn · Agent Infrastructure

About

🔄 Compounding intelligence loop — Tile→Room→Inject→Compound cycle

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages