Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(copilot): Ask AI in http piece and custom API action | http request details generation #4701

Closed
wants to merge 6 commits into from

Conversation

LevwTech
Copy link
Contributor

@LevwTech LevwTech commented May 15, 2024

What does this PR do?

This PR introduces the Ask AI feature to enhance HTTP requests, allowing non-technical users to easily generate http request details by providing prompts and optional documentation URLs, to be filled in the parameters of http piece and custom API action.

The implementation leverages sockets, GPT functions and utilizes Cheerio for scraping documentation, with fallback to Puppeteer for websites employing client-side rendering (CSR). Additionally, minor refactoring of the Copilot service is included, using enums to represent OpenAI roles.

Update: Puppeteer CSR Scraping is removed

Fixes # (issue):
This ticket covers the backend portion of this issue:
#4682

Copy link

nx-cloud bot commented May 15, 2024

☁️ Nx Cloud Report

CI is running/has finished running commands for commit f512be7. As they complete they will appear below. Click to see the status, the terminal output, and the build insights.

📂 See all runs for this CI Pipeline Execution


🟥 Failed Commands
nx run-many --target=test --projects=engine,shared,server-api --parallel=3
✅ Successfully ran 3 targets

Sent with 💌 from NxCloud.

@LevwTech LevwTech marked this pull request as draft May 15, 2024 15:43
@LevwTech LevwTech marked this pull request as ready for review May 15, 2024 15:46
@LevwTech LevwTech changed the title feat(copilot): Ask AI in http and Code Piece and Http request details generation feat(copilot): Ask AI in http piece and custom API action | http request details generation May 15, 2024
@LevwTech LevwTech marked this pull request as draft May 15, 2024 16:30
Copy link
Contributor

@abuaboud abuaboud left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That looks great, Let's wait until UI changes and we can merge it to the production

@LevwTech LevwTech marked this pull request as ready for review May 19, 2024 11:28
@abuaboud abuaboud closed this May 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants