👨‍💻 dev core diet

development

fukurou

the supreme coder
ADMIN
Python:
class Skill:
    def __init__(self) -> None:
        # Initialize protected attributes
        self.kokoro: Optional['Kokoro'] = None  # Shallow reference for interskill communication
        self.outAlg: Optional['Algorithm'] = None  # Skill's output
        self.outpAlgPriority: int = -1  # DEFCON levels 1->5

    def input(self, ear: str, skin: str, eye: str) -> None:
        # Implement skill triggers and algorithmic logic here
        pass

    def output(self, noiron: 'Neuron') -> None:
        # Extract and run the skill algorithm if available
        if self.outAlg is not None:
            noiron.insertAlg(self.outpAlgPriority, self.outAlg)
            self.outpAlgPriority = -1
            self.outAlg = None

    def setKokoro(self, kokoro: 'Kokoro') -> None:
        # Set Kokoro for interskill communication
        self.kokoro = kokoro

    def setVerbatimAlg(self, priority: int, *sayThis: str) -> None:
        # Build a simple output algorithm to speak string by string per think cycle
        self.outAlg = Algorithm(APVerbatim(*sayThis))
        self.outpAlgPriority = priority  # DEFCON levels 1->5

    def setSimpleAlg(self, *sayThis: str) -> None:
        # Shortcut to build a simple algorithm
        self.outAlg = Algorithm(APVerbatim(*sayThis))
        self.outpAlgPriority = 4  # Default priority of 4

    def setVerbatimAlgFromList(self, priority: int, sayThis: List[str]) -> None:
        # Build a simple output algorithm to speak string by string per think cycle using a list
        self.outAlg = Algorithm(APVerbatim(sayThis))
        self.outpAlgPriority = priority  # DEFCON levels 1->5

    def pendingAlgorithm(self) -> bool:
        # Check if an algorithm is pending
        return self.outAlg is not None

    def skillNotes(self, param: str) -> str:
        # Provide skill notes
        return "notes unknown"
 

fukurou

the supreme coder
ADMIN
Java:
    public void algPartsFusion(int priority, Mutatable... algParts) {
        this.outAlg = new Algorithm(algParts);
        this.outpAlgPriority = priority; // 1->5, 1 is the highest algorithm priority
    }
 
Top