ractogateway._cot
Chain-of-thought prompt injection utility.
Internal helper used by every developer kit when
ChatConfig(chain_of_thought=True) is set. The function is a pure
transformation — it never mutates the original prompt.
- ractogateway._cot.apply_chain_of_thought(prompt)[source]
Return a copy of prompt with a chain-of-thought constraint appended.
The original prompt is never mutated. The constraint is appended last so it appears at the bottom of the
[CONSTRAINTS]section and is processed after all caller-defined rules.- Parameters:
prompt (
RactoPrompt) – TheRactoPromptto augment.- Return type:
- Returns:
RactoPrompt – A new instance with the CoT constraint added.