HumanFirst icon

HumanFirst

Call HumanFirst playbook API

Overview

This node integrates with the HumanFirst API to manage and interact with playbooks and prompts within a specified namespace. The "Get Prompt" operation specifically retrieves detailed information about a single prompt identified by its Prompt ID from a given playbook.

Typical use cases include:

  • Fetching prompt details for review or processing in automation workflows.
  • Integrating prompt data into other systems or dashboards.
  • Validating prompt existence or content before updates or deletions.

For example, you might use this node to retrieve a prompt's configuration and contents to dynamically adjust chatbot behavior or to audit prompt definitions in your conversational AI system.

Properties

Name Meaning
Namespace The namespace under which the playbook and prompt are organized.
Playbook ID The unique identifier of the playbook containing the prompt.
Prompt ID The unique identifier of the prompt to retrieve.

Output

The output is a JSON object representing the retrieved prompt's full details as returned by the HumanFirst API. This typically includes fields such as the prompt's name, contents, model parameters, metadata, post-processing settings, and other configuration details.

No binary data is output by this operation.

Example output structure (simplified):

{
  "id": "promptId",
  "name": "Prompt Name",
  "contents": "Prompt text or template",
  "nlg_model_parameters": {
    "temperature": 1,
    "top_p": 1,
    "max_tokens": 0,
    "stop_sequences": [],
    "frequency_penalty": 0,
    "presence_penalty": 0
  },
  "post_processing": 1,
  "run_mode": 2,
  "metadata": {},
  "source": {},
  ...
}

Dependencies

  • Requires an API key credential for authenticating with the HumanFirst API.
  • The node makes HTTP GET requests to the HumanFirst API endpoint corresponding to the workspace, playbook, and prompt.
  • Proper network access to the HumanFirst API service is necessary.
  • The user must provide valid namespace, playbookId, and promptId values.

Troubleshooting

  • Error: Missing or invalid Prompt ID
    Ensure that the Prompt ID property is correctly set and corresponds to an existing prompt in the specified playbook.

  • Error: Unauthorized or authentication failure
    Verify that the API key credential is valid and has sufficient permissions to access the requested prompt.

  • Error: Network or API endpoint unreachable
    Check network connectivity and confirm the HumanFirst API base URL is accessible.

  • Error: Prompt not found
    Confirm that the prompt exists under the given namespace and playbook ID.

  • General API errors
    Review the error message returned in the JSON output for clues; ensure all required properties are provided and correctly formatted.

Links and References


This summary focuses on the "Get Prompt" operation of the HumanFirst node, describing its purpose, inputs, outputs, dependencies, and common troubleshooting tips based on static analysis of the source code and provided property definitions.

Discussion