Back to directory

Cataclysm

Cataclysm is a Python library that generates and executes code at runtime for any undefined function call, inferring an implementation from the function's name, arguments and surrounding context through an LLM.

Cataclysm

Cataclysm lets Python code call functions that were never defined: it infers an implementation from the function's name, its arguments and any nearby comments, generates code for it using an LLM, and runs the result. A global consume() mode generates fresh code for any unrecognized function anywhere in scope, useful for quick experimentation in notebooks or interactive sessions.

For use inside libraries or applications, a separate doom module generates and executes a single function at a time rather than acting globally, and preview modes let a developer inspect the code Cataclysm would generate, either once (impending) or as a fixed, reusable version (chosen doom), before it runs. It requires an OpenAI API key, since generation is powered by GPT-4, and installs via pip with an init command that copies default configuration files into a project.

More in Libraries

See all 292
  • OpenDecision

    deepanwadhwa.github.io

    An open-source Python package that answers typed questions about application state or documents using a local natural-language-inference model, returning structured choice, score, yes/no or evidence-relation values instead of free text.

  • TradeCanvas

    bonguynvan.github.io

    A zero-dependency canvas charting engine for building TradingView-style trading charts in JavaScript, with 66 technical indicators, 24 drawing tools, 17 chart types, and real-time streaming.

  • 3d retro graphics

    3d-retro.com

    A free, CC0-licensed library of copy-paste retro 3D and demoscene graphics effects, such as plasma, raytracing, and voxel terrain, runnable as WebGL 1 or plain 2D canvas.