Skip to content

**Cognition Breach** is a conversational simulation and visual novel that implements a **Finite Automaton (FA)** to model complex narrative states.This project uses a state-machine approach to manage transitions between three distinct "Realities" (States), where user input serves as the alphabet triggering state changes.

Notifications You must be signed in to change notification settings

Dupahar/Cognition-Breach

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Chatbot Using Finite Automaton (Cognition Breach)

Major Project for UMJDTT-502
Student: Adil Mahajan
Course: B. Tech (AI & MI) Semester 5

Project Overview

Cognition Breach is a conversational simulation and visual novel that implements a Finite Automaton (FA) to model complex narrative states. Unlike traditional linear chatbots, this project uses a state-machine approach to manage transitions between three distinct "Realities" (States), where user input serves as the alphabet triggering state changes.

The project demonstrates:

  1. Finite Automata Concepts: The entire narrative structure models a DFA (Deterministic Finite Automaton) where nodes are story states and edges are user choices.
  2. Rule-Based Chat System ("Cognet"): A simulated real-time messenger that connects three distinct personalities (Kaelen, IRIS-7, Lyra), each representing a different state of reality.
  3. State Transitions: Dynamic switching between Physical, Digital, and Spiritual layers based on user interaction.

Technical Description

The Finite Automaton Model

The system is designed as a tuple $M = (Q, \Sigma, \delta, q_0, F)$:

  • States ($Q$): The set of active realities {"Kaelen" (Physical), "IRIS" (Digital), "Lyra" (Spiritual)}.
  • Input Alphabet ($\Sigma$): User choices in the Cognet chat interface and Truth Matrix.
  • Transition Function ($\delta$): The logic defining how a choice moves the narrative from one reality view to another (e.g., Switch -> Digital).
  • Start State ($q_0$): The "White Noise" event (Initial Fracture).
  • Final States ($F$): The "Core" convergence sequence / Demo Conclusion.

Key Features

  • Rashomon Effect Implementation: The same "event" (input) produces different outputs depending on the current state (Reality Layer).
  • Cognet Chat Interface: A visual representation of the rule-based dialogue system.
  • Truth Matrix: A persistent data store that validates state consistency across transitions.

Project Structure

  • game/simple_chat.rpy: Implementation of the chat buffer and message handling logic.
  • game/script.rpy: The main state machine definition (Labels and Menus).
  • game/screens.rpy: UI definitions for the state visualization.

How to Run

  1. Ensure you have Ren'Py 8.5.0 or later installed (or use the provided executable).
  2. Clone this repository.
  3. Launch the project using the Ren'Py launcher.

Future Scope

  • Expansion of the alphabet ($\Sigma$) to include Natural Language Processing (NLP) inputs.
  • Complex non-deterministic transitions based on probabilistic "glitches".

Created by Adil Mahajan for Skill Incubation Innovation Entrepreneurship Development Centre, University of Jammu.

About

**Cognition Breach** is a conversational simulation and visual novel that implements a **Finite Automaton (FA)** to model complex narrative states.This project uses a state-machine approach to manage transitions between three distinct "Realities" (States), where user input serves as the alphabet triggering state changes.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages