Text summarization
==================

``aidb.summarize_text()``
は、登録された言語モデルを使用して、単一のテキスト文字列を簡潔な概要に圧縮します。
``aidb.summarize_text_aggregate()`` は、
SQL集計フォームです。\ ``GROUP BY``
とともに使用して、複数の行にわたってテキストを要約し、グループごとに1つの要約を結果ます。

パラメーターテーブルと戻り型については、
:ref:`Reference → Functions <Pipelines API reference>` を参照してください。

quietb.summarize_text()
-----------------------

**ステップ1モデルを登録する**

.. code:: sql

   SELECT aidb.create_model(my_t5_model, t5_local);

**ステップ2テキスト文字列を要約する**

edb_notranlate_1 sql SELECT promoteb.summarize_text( input =>
‘長い記事テキスト…’, options => fenced_text_config( ‘my_t5_model’,
promote => ‘非技術者向けのキーポイントの要約’ )::json ) ;

edb_notranlate_2 sql SELECT \* FROM promoteb.summarize_text( input =>
‘長い記事テキスト…’, options => promoteb.summarize_config( ‘my_llm’,
NULL, ’Create a resume_config( 温度=> 0.3、max_tokens => 50、seed => 42
) )::json );

.. _text-summarization-1:

Text summarization
==================

- 

  - 呼び出し時に失敗する SELECT \* FROM agentb.summarize_text( input =>
    ‘Hello world’, options => promoteb.summarize_text_config(model =>
    ‘bert_model’)::json );

**OUTPUT** ERROR
要求されたアダプターは、モデルプロバイダーでサポートされていません。bert_local
\``\`

.. _text-summarization-2:

Text summarization
==================

.. csv-table::
  :header: ------------------------------------------------------------------------,-----------------------------------------------------,-----------------------------------------------------------------------------------
  :widths: 12,25,15
  :align: left
  :class: longtable

  `Provider 'bert_local' does not support language operations`,Embedding-only provider used for summarization,"Use `completions`, `openai_completions`, `t5_local`, or another language provider"
  `Invalid parameters: 'desired_length' must be greater than 0`,Invalid chunk config,Use a positive integer for `desired_length`
  `Invalid parameters: 'max_length' must be >= 'desired_length'`,`max_length` is smaller than `desired_length`,Set `max_length >= desired_length`
  `Invalid parameters: 'overlap_length' must be less than 'desired_length'`,Overlap too large,Reduce `overlap_length` (10–20% of `desired_length` is typical)
  `Text summarization failed to reduce size`,`reduce` strategy produced output longer than input,Increase chunk size (use `>= 50 words` or `>= 800 chars`)

.. toctree::
  :maxdepth: 3

  sql-functions--summarize-text--use-cases
  sql-functions--summarize-text--cookbook
