GoogleCloudPlatform / dfcx-scrapi

A high level scripting API for bot builders, developers, and maintainers.
Apache License 2.0
90 stars 59 forks source link

[FR] Parameters to DataFrame #32

Open kmaphoenix opened 2 years ago

kmaphoenix commented 2 years ago

Is your proposal related to a problem?

As a user, it is difficult to know what Parameters are "active" across the CX Agent at any given time since CX Agents can have numerous Flows / Pages and it can be hard to track all of the various Parameters.

Describe the solution you'd like

Similar to bulk_intent_to_df we should include a method that allows the user to extract all Form Parameters, their associated Entity Types, and any Form Settings (i.e. redact in log, etc.) that may be available in a CX Agent at design-time.

Greenford commented 2 years ago

I have a nearly-ready solution for this. A few questions -

  1. Do we want location information like flow name, page name also? I assume we do, since the user would likely need to edit them.
  2. Do we want set_parameter_actions also? I think that'd be useful. For reference, here's the class & location in fulfillment
Greenford commented 2 years ago

Per our conversation today:

1 & 2: yes & yes Form params: record 3 checkboxes like is_required too.

ALSO we want everywhere in the fulfillments that parameters are referenced. find which fulfillment-referenced parameters are set by webhook (not set by set_parameter_actions or from a form)

Greenford commented 2 years ago

@SeanScripts you said you've worked on this a bit? May I see your code?

Greenford commented 2 years ago

Making a note for myself to include conditional routes in the parameter return

kmaphoenix commented 2 years ago

Ping @Greenford and @SeanScripts !

Was there any progress on this one?

Greenford commented 2 years ago

I got it halfway completed maybe 3 weeks ago, but then realized it needed more types of data to fulfill the overall goal for this issue. Still planning to work on it!

SeanScripts commented 1 year ago

@skyyeat and I worked on a function in search util to get all the parameter presets in the agent as a dataframe. It's not quite the same as this issue, but it is closely related. The work is in branch feature/search_util_update