Skip to content

FastHTML examples#496

Merged
bnusunny merged 2 commits intoaws:mainfrom
stephenhibbert:fasthtml
Sep 3, 2024
Merged

FastHTML examples#496
bnusunny merged 2 commits intoaws:mainfrom
stephenhibbert:fasthtml

Conversation

@stephenhibbert
Copy link
Copy Markdown
Contributor

@stephenhibbert stephenhibbert commented Sep 3, 2024

#495

Added four new FastHTML examples

  • FastHTML - examples/fasthtml
  • FastHTML in Zip - examples/fasthtml-zip
  • FastHTML with Response Streaming - examples/fasthtml-response-streaming
  • FastHTML with Response Streaming in Zip - examples/fasthtml-response-streaming-zip

For streaming, using HTMX chunked transfer extension. With HTMX it's also possible to do polling or websockets (don't think that's supported on aws-lambda-web-adapter?)

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@@ -0,0 +1,62 @@
from anthropic import AnthropicBedrock
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Any reason to use AnthropicBedrock instead of boto3? If you need to use it, the README and requirementes.txt should be updated .

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Have made the correction, I prefer to use it because of the simple streaming support and making it easier to use the Instructor module for structured output. The trade off is naturally it restricts the models to Anthropic only.

@bnusunny
Copy link
Copy Markdown
Contributor

bnusunny commented Sep 3, 2024

Thanks for the contribution!

@bnusunny bnusunny merged commit ee72441 into aws:main Sep 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants