Commit Graph
8 Commits
Author SHA1 Message Date
Roman Rizzi b076e43d67 FEATURE: streaming mode for the FoldContent strategy. (#134) 2023-08-11 15:08:54 -03:00
Rafael dos Santos Silva eb7fff3a55 FEATURE: Add support for StableBeluga and Upstage Llama2 instruct (#126)
* FEATURE: Add support for StableBeluga and Upstage Llama2 instruct

This means we support all models in the top3 of the Open LLM Leaderboard

Since some of those models have RoPE, we now have a setting so you can
customize the token limit depending which model you use.
2023-08-03 15:29:30 -03:00
Rafael dos Santos Silva 8b157feea5 FEATURE: Compatibility with protected Hugging Face Endpoints (#123)
* FEATURE: Compatibility with protected Hugging Face Endpoints
2023-08-02 17:00:00 -03:00
Rafael dos Santos Silva b25daed60b FEATURE: Llama2 for summarization (#116) 2023-07-27 13:55:32 -03:00
Roman Rizzi 473732c18a FIX: Return base prompt instead of nil (#106) 2023-07-13 21:48:25 -03:00
Roman Rizzi 5f0c617880 REFACTOR: Cohesive narrative for single-chunk summaries. (#103)
Single and multi-chunk summaries end using different prompts for the last summary. This change detects when the summarized content fits in a single chunk and uses a slightly different prompt, which leads to more consistent summary formats.

This PR also moves the chunk-splitting step to the `FoldContent` strategy as preparation for implementing streamed summaries.
2023-07-13 17:05:41 -03:00
Roman Rizzi fbe1bab980 FIX: typo while updating a section (#98) 2023-06-27 17:57:58 -03:00
Roman Rizzi 9a79afcdbf DEV: Better strategies for summarization (#88)
* DEV: Better strategies for summarization

The strategy responsibility needs to be "Given a collection of texts, I know how to summarize them most efficiently, using the minimum amount of requests and maximizing token usage".

There are different token limits for each model, so it all boils down to two different strategies:

Fold all these texts into a single one, doing the summarization in chunks, and then build a summary from those.
Build it by combining texts in a single prompt, and truncate it according to your token limits.

While the latter is less than ideal, we need it for "bart-large-cnn-samsum" and "flan-t5-base-samsum", both with low limits. The rest will rely on folding.

* Expose summarized chunks to users
2023-06-27 12:26:33 -03:00