Skip to content

Commit

Permalink
Revert structure check
Browse files Browse the repository at this point in the history
  • Loading branch information
collindutter committed Feb 12, 2024
1 parent 503bc47 commit 1b668b0
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions griptape/drivers/prompt/base_prompt_driver.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,10 +79,7 @@ def run(self, prompt_stack: PromptStack) -> TextArtifact:
tokens = []
completion_chunks = self.try_stream(prompt_stack)
for chunk in completion_chunks:
if self.structure:
self.structure.publish_event(CompletionChunkEvent(token=chunk.value))
else:
raise ValueError("Streaming requires a structure")
self.structure.publish_event(CompletionChunkEvent(token=chunk.value))
tokens.append(chunk.value)
result = TextArtifact(value="".join(tokens).strip())
else:
Expand Down

0 comments on commit 1b668b0

Please sign in to comment.