Summary of content returns text "requested value".

Created on 1 April 2024, 9 months ago
Updated 3 April 2024, 9 months ago

Problem/Motivation

Summary of content returns text "requested value".

Steps to reproduce

Drupal 10.2.4
- lando composer require 'drupal/ai_interpolator:^1.0@RC'
- lando composer require 'drupal/openai:^1.0@beta'
- lando composer require 'drupal/ai_interpolator_openai:^1.0@RC'

Followed instructions at https://www.drupal.org/docs/extending-drupal/contributed-modules/contrib... under #How to use

Tried 4 times creating nodes, and each time the summary field is populated with text "requested value". ie. The body field is not summarised.

No error messages in site log.

My account at OpenAI shows the API requests are received. I tried GPT-3.5-turbo and GPT-4. Same result.

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

🐛 Bug report
Status

Active

Version

1.0

Component

User interface

Created by

🇦🇺Australia JDSaward

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @JDSaward
  • Assigned to marcus_johansson
  • 🇩🇪Germany marcus_johansson

    @JDSaward

    Just a couple of questions to be able to debug this:

    1. Is this part of a chain of rules, and could you describe it then?
    2. Do you have a paid OpenAI Account?
    3. Could you write down the prompt you are using?
    4. If possible - could you provide the text of the source you are using - obfuscated would be ok as well if there are company secrets?
  • 🇦🇺Australia JDSaward

    @Marcus_Johansson Thanks for reply.

    1.
    It is not a chain of rules. All I have done so far is to test the #How to use. I'm really only just now in first evaluation of the module.

    So, I created a content type that I named 'Interpolator Tester', with a long text body field and a long text summary field.

    In the field settings for the summary field I ticked 'Enable AI Interpolator'.

    Then I selected the AI Interpolator Rule, 'OpenAI Text Long' .

    2.

    Yes I have an Open AI account.

    3.

    I used the suggested prompt from #How to use:

    Based on the context text, generate a one sentence summary.

    Context:
    ------------------------
    {{ context }}

    4. I tried various sample texts, the latest I just copied form Wikipedia:

    Wikipedia:

    Drupal (/ˈdruːpəl/)[5] is a free and open-source web content management system (CMS) written in PHP and distributed under the GNU General Public License.[4][6][7] Drupal provides an open-source back-end framework for at least 14% of the top 10,000 websites worldwide[8] and 1.2% of the top 10 million websites[9]—ranging from personal blogs to corporate, political, and government sites.[10] Drupal can also be used for knowledge management and for business collaboration.[11]

    As of March 2022, the Drupal community had more than 1.39 million members,[12][13][14] including 124,000 users actively contributing,[15] resulting in more than 50,000 free modules that extend and customize Drupal functionality,[16] over 3,000 free themes that change the look and feel of Drupal,[17] and at least 1,400 free distributions that allow users to quickly and easily set up a complex, use-specific Drupal in fewer steps.[18]

    The standard release of Drupal, known as Drupal core, contains basic features common to content-management systems. These include user account registration and maintenance, menu management, RSS feeds, taxonomy, page layout customization, and system administration. The Drupal core installation can serve as a simple website, a single- or multi-user blog, an Internet forum, or a community website providing for user-generated content.

    Drupal also describes itself as a Web application framework.[19] When compared with notable frameworks, Drupal meets most of the generally accepted feature requirements for such web frameworks.[20][21]

    Although Drupal offers a sophisticated API for developers, basic Web-site installation and administration of the framework require no programming skills.[22]

    Drupal runs on any computing platform that supports both a web server capable of running PHP and a database to store content and configuration.

Production build 0.71.5 2024