Skip to content

docs: fix output rail doc #1159

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from

Conversation

andompesta
Copy link

@andompesta andompesta commented Apr 29, 2025

Description

Fix some issues on output streaming rails documentation.
Specifically the streaming.enabled field was missing

Related Issue(s)

I haven't opened a proper issue for that

Checklist

  • I've read the CONTRIBUTING guidelines.
  • I've updated the documentation if applicable.
  • I've added tests if applicable.
  • @mentions of the person or team responsible for reviewing proposed changes.

@andompesta andompesta changed the title Doc/fix output rail doc docs:fix output rail doc Apr 29, 2025
@andompesta andompesta changed the title docs:fix output rail doc docs: fix output rail doc Apr 29, 2025
Copy link
Member

@mikemckiernan mikemckiernan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks very much for the contribution and corrections! If you don't have time for the requested changes, just let me know and I can add them to this PR and bring them in with your changes.

@@ -185,9 +185,11 @@ You can enable streaming to provide asynchronous responses and reduce the time t
streaming:
chunk_size: 200
context_size: 50
enabled: True
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you mind making this the first field underneath streaming:?


streaming: True
```
Note that, the `enabled: True` filed is needed to enable streaming output rails while `streaming: True` is needed to enable streaming generation.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please remove "Note that," and start with "The enabled...." Please also add a line above for ease of review by future maintainers. (nit: typo for field.)

@Pouyanpi, is the description for the top-level streaming field accurate? (I wish that I knew better myself.)

@@ -689,6 +689,7 @@ rails:
chunk_size: 200
context_size: 50
stream_first: True
enabled: True
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As with the previous comment, do you mind making this the first field beneath "streaming:"?

@@ -742,6 +743,11 @@ The following table describes the subfields for the `streaming` field:
By default, the toolkit streams the chunks as soon as possible and before applying output rails to them.

- `True`

* - streaming.enabled
- When set to True enable the execution of the output rails in streaming mode.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you mind putting this row in alphabetical order?

Thanks for following the "When set..." pattern. Do you mind enclosing True in backticks (True) and following with a comma? Maybe also revise to "When set to True, the toolkit executes output rails in streaming mode."

@mikemckiernan mikemckiernan added the documentation Improvements or additions to documentation label May 2, 2025
@mikemckiernan mikemckiernan requested a review from Pouyanpi May 2, 2025 18:04
@mikemckiernan mikemckiernan added this to the v0.14.0 milestone May 2, 2025
Copy link

github-actions bot commented May 2, 2025

Documentation preview

https://nvidia.github.io/NeMo-Guardrails/review/pr-1159

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants