Repository is archived
No release in over 3 years
Models mosaic assembly: tesserae (individual cognitive fragments) placed into mosaics with pattern categories, grout strength for cohesion, coherence scoring, gap detection for missing pieces.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
 Dependencies

Development

 Project Readme

lex-cognitive-mosaic

Knowledge assembly engine for LegionIO cognitive agents. Individual tesserae (knowledge pieces) are placed into mosaics (knowledge structures) with pattern categories and grout that holds them together. Grout erodes over time and must be reinforced to prevent crumbling.

What It Does

  • Ten tessera material types: glass, stone, ceramic, metal, wood, shell, bone, crystal, clay, enamel
  • Seven mosaic pattern categories: geometric, organic, abstract, narrative, symbolic, decorative, functional
  • Place tesserae into mosaics with fit quality scores
  • Track mosaic completeness (filled / capacity), coherence, and grout strength
  • Grout decays per cycle (erode_grout!); reinforce to maintain structural integrity
  • Detect crumbling mosaics (low grout) and full mosaics
  • List loose (unplaced) tesserae

Usage

# Create tesserae
t1 = runner.create_tessera(content: 'service boundary pattern',
                             material_type: :crystal, color: 'blue', fit_quality: 0.8)
t2 = runner.create_tessera(content: 'dependency inversion principle',
                             material_type: :stone, color: 'grey', fit_quality: 0.9)

# Create a mosaic
m = runner.create_mosaic(name: 'architecture_principles',
                          pattern_category: :structural, capacity: 20)

# Place tesserae
runner.place_tessera(tessera_id: t1[:tessera][:id], mosaic_id: m[:mosaic][:id])
runner.place_tessera(tessera_id: t2[:tessera][:id], mosaic_id: m[:mosaic][:id])

# Check status
runner.mosaic_status(mosaic_id: m[:mosaic][:id])
# => { success: true, mosaic: { completeness: 0.1, grout_strength: 0.9, crumbling: false, gap_count: 18, ... } }

# List unplaced tesserae
runner.list_tesserae(loose_only: true)

Development

bundle install
bundle exec rspec
bundle exec rubocop

License

MIT