Complete Tutorial
End-to-end walkthrough: From signup to a working Helper on your website
This tutorial will guide you through the complete process of integrating AI Anywhere into your website. By the end, you'll have a fully functional Helper that provides intelligent text assistance to your users.
Two ways to use your Helper
Every helper is available in two ways:
- Helper Page (no code): You get a shareable Helper Page link instantly. Open it from the dashboard by going to your Helper and clicking the "Helper Page" button (on the Helper's edit or detail page). Share the link with anyone; no snippet or integration required.
- Embed on your site: Add a small script and anchor to your website so the Helper button appears next to your text areas. Users get assistance without leaving your page.
This tutorial focuses on the embed option. To use the Helper Page, create a Helper in the dashboard and click "Helper Page" to open or share the link.
Create Your Account
First, you need to sign up for an AI Anywhere account.
- Go to the AI Anywhere homepage
- Click the "Get Started" button in the header
- Sign up using your preferred social account (Google, GitHub, etc.)
- You'll be automatically logged into your dashboard
Create Your First Helper
Now let's create a Helper that will assist users with writing contact form messages.
- In your dashboard, click "New Helper"
- Give your Helper a descriptive name, such as
"Contact Form Helper" - Select the site where this Helper will be used
- Click "Save Helper"
Configure Your Helper
After creating the Helper, you'll need to configure it:
- Helper Answer: Enter a well-written example of what you want users to write. For a contact form, this might be a complete, professional message that includes all necessary information. The example should be complete with mock names, specific details, and realistic content (e.g., "Hello, I'm John Smith writing to inquire about your web development services. I'm particularly interested in building an e-commerce platform for my business. Could you please provide more information about your pricing and timeline? Thank you for your time.").
- Keywords and/or Rules: Add keywords or rules that are important for your use case (e.g., "contact", "inquiry", "question", "support").
- Button Styling: Customize the Helper button's appearance (color, text) to match your site's design.
Get Your Integration Code
Now you need to get the code snippets that will integrate the Helper into your website.
- In your Helper settings, click the "Generate Snippet" button
- You'll see two code snippets:
- Script tag: Contains your site ID
- Anchor span: Contains your Helper token
- Copy both snippets - you'll need them in the next step
Your snippets will look like this:
<!-- Script tag (goes in <head>) -->
<script src="https://ai-anywhere.ai/sdk/v1/loader.js" data-site="your-site-id"></script>
<!-- Anchor span (goes next to your text area) -->
<span data-helper-anchor data-helper-token="your-helper-token"></span>
<head> section and is the same for all pages. The anchor span with your Helper token goes next to each text area where you want the Helper to appear.
Add the Script to Your HTML
Now let's add the Helper script to your website's HTML.
- Open your HTML file (or template file if using a framework)
- Find the
<head>section - Paste the script tag before the closing
</head>tag
Here's what it should look like:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Contact Us</title>
<!-- AI Anywhere Helper Script -->
<script src="https://ai-anywhere.ai/sdk/v1/loader.js" data-site="your-site-id"></script>
</head>
<head> section, after meta tags but before other scripts. This ensures the Helper loads early.
Add the Helper Anchor to Your Form
Now add the anchor span next to your text area where you want the Helper button to appear.
- Find your contact form (or the form where you want the Helper)
- Locate the text area where users will type their message
- Add the anchor span right after the text area (or in a nearby location)
Here's a complete example of a contact form with the Helper:
<form id="contact-form">
<div>
<label for="name">Name:</label>
<input type="text" id="name" name="name" required>
</div>
<div>
<label for="email">Email:</label>
<input type="email" id="email" name="email" required>
</div>
<div>
<label for="message">Message:</label>
<textarea id="message" name="message" rows="6" required></textarea>
<!-- Helper anchor - button will appear here -->
<span data-helper-anchor data-helper-token="your-helper-token"></span>
</div>
<button type="submit">Send Message</button>
</form>
Test Your Helper
Now let's verify that everything is working correctly.
- Save your HTML file
- Open your website in a web browser
- Navigate to the page with your contact form
- Look for the Helper button next to your text area
What to Check
- The Helper button appears next to your text area
- The button has the correct styling (color, text, size) that you configured
- When you click the button, the Helper interface opens
- When you type text and click the Helper button, it provides suggestions
Troubleshooting
If the Helper button doesn't appear:
- Check your browser's developer console (F12) for any JavaScript errors
- Verify that the script tag is correctly placed in the
<head>section - Ensure the anchor span is present and contains the correct Helper token
- Try a hard refresh (Ctrl+Shift+R or Cmd+Shift+R) to clear cached files
- Check that your site ID and Helper token are correct
Customize Your Helper (Optional)
Now that your Helper is working, you can customize it to better match your needs.
What You Can Customize
- Button Appearance: Change the color and text of the Helper button.
- Helper Answer: Update the example to better reflect what you want users to write
- Keywords: Add or remove keywords to improve suggestion accuracy
- Multiple Helpers: Create additional Helpers for different forms or text areas
To customize:
- Go back to your dashboard
- Select "Helpers", then select the specific Helper you want to edit
- Click the "Edit" button
- Make your changes
- Save your changes
Deploy to Production
Once you've tested everything locally, it's time to deploy to your production website.
Pre-Deployment Checklist
- Tested the Helper on your local/staging environment
- Verified the Helper button appears and works correctly
- Tested with different browsers (Chrome, Firefox, Safari, Edge)
- Tested on mobile devices
- Verified the Helper suggestions are helpful and accurate
Deployment Steps
- Upload your updated HTML files to your web server
- Verify the script tag is in the
<head>of all pages where you want the Helper - Verify the anchor spans are placed correctly next to your text areas
- Test the Helper on your live website
- Monitor for any issues or errors
- The same script tag (with your site ID) can be used on all pages
- Each text area can have its own Helper with a different token
- You can add multiple Helpers to the same page for different form fields
Congratulations!
You've successfully integrated AI Anywhere into your website! Your Helper is now live and ready to assist your users.
What's Next?
- Learn about advanced configuration options
- Explore theming and customization to match your brand
- Check out code examples for different use cases
- Read about security and privacy features
- If you run into issues, visit our troubleshooting guide