Skip to content

Class swarmauri_core.prompts.IPromptMatrix.IPromptMatrix

swarmauri_core.prompts.IPromptMatrix.IPromptMatrix

Bases: ABC

shape abstractmethod property

shape

Get the shape (number of agents, sequence length) of the prompt matrix.

add_prompt_sequence abstractmethod

add_prompt_sequence(sequence)

Add a new prompt sequence to the matrix.

Source code in swarmauri_core/prompts/IPromptMatrix.py
12
13
14
15
@abstractmethod
def add_prompt_sequence(self, sequence: List[Optional[str]]) -> None:
    """Add a new prompt sequence to the matrix."""
    pass

remove_prompt_sequence abstractmethod

remove_prompt_sequence(index)

Remove a prompt sequence from the matrix by index.

Source code in swarmauri_core/prompts/IPromptMatrix.py
17
18
19
20
@abstractmethod
def remove_prompt_sequence(self, index: int) -> None:
    """Remove a prompt sequence from the matrix by index."""
    pass

get_prompt_sequence abstractmethod

get_prompt_sequence(index)

Get a prompt sequence from the matrix by index.

Source code in swarmauri_core/prompts/IPromptMatrix.py
22
23
24
25
@abstractmethod
def get_prompt_sequence(self, index: int) -> List[Optional[str]]:
    """Get a prompt sequence from the matrix by index."""
    pass

show abstractmethod

show()

Show the entire prompt matrix.

Source code in swarmauri_core/prompts/IPromptMatrix.py
27
28
29
30
@abstractmethod
def show(self) -> List[List[Optional[str]]]:
    """Show the entire prompt matrix."""
    pass