=== Sabriel AI ===
Contributors: sabrielagency
Tags: chatbot, ai assistant, live chat, customer support, virtual assistant
Requires at least: 6.0
Tested up to: 7.0
Requires PHP: 7.4
Stable tag: 1.0.27
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

A white-label AI chat assistant. Bring your own key for Gemini, OpenAI or Claude. Fully customizable, 9 languages, no account required.

== Description ==

Sabriel AI puts a real AI assistant on your site, styled to look like it was built for your brand, not like a widget you bolted on.

You connect **your own API key** for Google Gemini, OpenAI or Anthropic Claude. The key is stored encrypted on your site and is only ever sent to the provider you chose. There is no account to create, no service in the middle, and no data of yours passes through us.

= What the assistant can do =

* Answer questions about your business, using the details and the price list you enter in the settings
* Speak the language your visitor writes in, and switch mid-conversation if they do
* Read images your visitor attaches, and PDFs too when the engine you picked supports them
* Take voice messages: speech becomes text inside the visitor's own browser, so no audio ever leaves their device
* Know your opening hours, and tell a visitor writing at 11pm that you are closed instead of letting them wait
* Quote in your currency, with your VAT rate and your payment terms, exactly as you set them
* Hand the conversation over to a human, with WhatsApp, email and phone buttons and the message already written
* Take a written message when nobody is available, and send it to you by email
* Email the visitor a tidy summary of the conversation when they leave, and notify you at the same time
* Recognise a visitor who comes back from the same device, and pick up from what you already talked about

= What you get in the admin panel =

* **A setup wizard that does the boring part.** It reads your homepage with the AI you just connected and suggests a tagline and a tone of voice for your assistant. It also pulls your business name, website and email straight from WordPress, and your address from WooCommerce if you have it. You approve what you want and skip the rest.
* **Seven ready-made tones** — e-commerce, professional practice, salon, restaurant, medical practice, craftsperson, estate agency — as a starting point you then edit in your own words.
* **A dashboard** with visits, unique visitors, chats opened, daily average, blocked abuse attempts and your most visited pages, over the last 90 days. Counted on your own site, without cookies.
* **A system status page** that checks the things that actually break: whether your key is readable, whether the server can encrypt it, whether your site can send email at all. With a real test button for each.
* **Export and import** of the whole configuration, to move a finished setup onto the next site.

= What you control =

* **Your brand.** Logo, bot name and the widget's main colours, with a live preview while you pick them. No credit of ours appears unless you choose to switch it on.
* **Behaviour and tone.** A plain-text field where you tell the assistant how to talk and what your rules are.
* **Your price list.** One row per service, with price and short description. The assistant quotes from it instead of inventing numbers.
* **Opening hours**, including shifts that cross midnight: the plugin splits them across the two days by itself.
* **Currency and VAT**, by country, with the rate filled in for you, and your deposit/balance structure.
* **Links to your pages.** The assistant cites them naturally when they are relevant, and never invents an address that does not exist.
* **Anti-abuse limits.** How many messages one visitor gets in 24 hours — a number you set, not one we impose — how many conversation summaries a single address can receive in an hour, and disposable email addresses turned away.

= Nine languages, out of the box =

Italian, English, Spanish, French, German, Portuguese, Dutch, Russian and Indonesian: for both the assistant and the admin panel, and they can be different from each other.

= Documentation inside the plugin =

There is a full Documentation page in the admin menu, with live previews that reflect your actual configuration. You can also export it as a single HTML file and publish it on your own site for your team.

= A larger version exists =


Nothing here is locked. The paid edition is a separate plugin, not a key that unlocks code you already downloaded: none of the features listed above ship inside this download in a disabled state.

It is **not** required and this plugin does not nag you about it: everything described above works on its own, for everyone, forever. Details are on a single page inside the plugin, and at https://sabrielagency.com/sabriel-ai/

== Installation ==

1. Install the plugin from Plugins → Add New, or upload the folder to `/wp-content/plugins/`.
2. Activate it. The setup wizard opens by itself.
3. Choose the assistant's language and enter your business details.
4. Pick an AI engine and paste your API key. Google Gemini offers a free tier that is enough to get started.
5. Save. The chat widget appears on your site right away.

== Frequently Asked Questions ==

= Do I need to create an account? =

No. There is no registration, no license key and no service of ours in the middle. You only need an API key from the AI provider you choose.

= Where do I get an API key? =

Google Gemini: https://aistudio.google.com/apikey | OpenAI: https://platform.openai.com/api-keys | Anthropic Claude: https://console.anthropic.com/

= What does it cost to run? =

You pay your AI provider for what the assistant actually uses, at their published rates. The plugin adds nothing on top. A small business site typically spends very little per month.

= Is my API key safe? =

It is encrypted before being written to your database, and it is never shown again in the admin panel once saved. It is only sent to the provider you selected, over HTTPS.

= Can I change AI provider later? =

Yes, at any time, without losing anything. Each provider keeps its own key.

= Does it work in my language? =

The interface ships in nine languages. The assistant itself replies in whatever language the visitor writes in, whichever one that is.

= Does it slow down my site? =

The widget loads its own small stylesheet and script and nothing else. There are no external fonts and no third-party trackers. The only server the site ever contacts is the AI provider you configured, and only when a visitor writes in the chat. See "External services" below.

== External services ==

This plugin relies on one external service, and only on one: the AI provider you choose. Nothing is sent anywhere until you configure it.

**The AI provider you choose.** To answer a visitor, the plugin sends the conversation (the visitor's messages, any attachment, and the business information you entered (price list, opening hours, contacts) to the provider you selected, using your own API key. It is sent only when a visitor writes in the chat, and only to the one provider that is active. No copy is sent anywhere else.

* Google Gemini: terms https://ai.google.dev/gemini-api/terms | privacy https://policies.google.com/privacy
* OpenAI: terms https://openai.com/policies/ | privacy https://openai.com/policies/privacy-policy
* Anthropic Claude: terms https://www.anthropic.com/legal/commercial-terms | privacy https://www.anthropic.com/legal/privacy

The plugin never contacts any server belonging to Sabriel Agency, and collects no usage statistics.

**Reporting a problem (optional, and only if you ask for it).** The System status page has a form that emails a bug report to the plugin author, through your own site's mail system. It carries what you write, the address you give for a reply, your site address and the technical summary shown on that same page. Nothing is sent unless you fill that form in and submit it.

== Privacy ==

**What leaves your site, and where it goes.**

When a visitor writes in the chat, their message, together with any attachment and the business information you entered (price list, opening details, contacts), is sent to the AI provider **you** selected, using **your** API key. That is how the assistant answers: without that request there would be no reply.

How that data is handled, and for how long it is kept, is decided by that provider, not by this plugin. Their terms apply:

* Google Gemini: https://ai.google.dev/gemini-api/terms
* OpenAI: https://openai.com/policies/
* Anthropic Claude: https://www.anthropic.com/legal/commercial-terms

**Visit statistics (you can switch them off).** To count returning visitors without writing a cookie, the widget builds a short code from a few browser characteristics (screen size, language, time zone, platform) and sends it to your own site together with the page address. It never leaves your site and it is not readable back into those characteristics, but in the EU this still counts as accessing the visitor's device: if you do not ask for consent, turn the option off in Settings → Limits. The chat works exactly the same either way.

**What stays on your site.** The visit counters are stored in your own WordPress database. The name, email and past conversations a visitor types into the chat stay in that visitor's own browser and are never written to your database: the assistant recognises someone returning on the same device because the browser tells it, not because the site kept a record. Nothing is sent to Sabriel Agency.

**Emails.** The conversation summary is sent to the visitor's own address and to the address you configured, through your site's normal mail system.

**Removing everything.** Deleting the plugin from the Plugins screen removes its settings, its visit counters and its scheduled tasks. Anything belonging to your customers is only removed if you first switch on "Also delete customer data" in Settings: it is off by default, so uninstalling in order to reinstall never loses anything. It also clears leftover data from the paid edition, if the site ever ran it.

== Screenshots ==

1. The chat widget on a live site, in the colours of the business.
2. The customization page: logo, bot name and colours, with the live preview.
3. The AI engine page: three providers, your own key, and the price of every model.
4. Settings: business details, price list and page links.
5. The setup wizard, which reads your homepage and suggests a tone of voice.
6. System status: what is configured, what is missing, and a real test for each.
7. The documentation, built into the plugin and exportable as a single HTML file.

== Changelog ==

= 1.0.27 =
* WooCommerce: the assistant now knows your products properly. Variants, attributes, tags, categories, price and stock all reach it, so a customer can ask for a dish without a certain sauce or a hoodie in a certain colour and get the right ones — across the whole catalogue, with nothing to tick anywhere. It also knows what it has just shown, so it can answer questions about those products.
* Bookings: when a time is taken, the assistant says so straight away and offers the free ones instead of asking for all the details first. Opening hours that run past midnight are now read out as one shift — Monday 15:00-02:00 — rather than split across two days.
* The assistant no longer assumes your business sells custom projects or websites. When a request clearly belongs to another trade it says so kindly, and offers neither an appointment nor a quote for something you do not do.
* Language: the bot now follows your language settings from the customer's very first message, whichever of the nine languages you use.
* Quote PDFs accept logos in every common image format.
* The plugin links to its own product page instead of the site homepage.
* The conversation summary now reaches you from phones too. It used to be sent only when the browser announced the page was closing, which phones never do — they freeze the page instead, so summaries from mobile visitors were quietly lost.
* Chat history no longer stops saving without warning when the browser runs out of storage: the oldest conversations make room for the one in progress, and the visitor is told if even that is not enough.

= 1.0.22 =
* Added Gemini 3.5 Flash-Lite to the model list. The recommended model does not change: 3.1 Flash-Lite still costs less.
* The plan comparison listed two things as missing that this edition actually has: there is no Sabriel AI credit in the chat footer, and updates arrive from WordPress.org like any other plugin. Both are now listed as included.
* The manual pointed to the wrong tab for the visit-statistics switch, and printed its label in English inside the other eight languages.
* The reset warning on the Customization page listed settings this edition does not have.
* The manual's contents list was missing an entry, and its section headings now use the same icons as the rest of the plugin.
* New: an optional "Powered by Sabriel AI" credit under the chat, off by default. It is your choice, it changes nothing else, and the appearance reset leaves it alone.
* Importing a configuration exported from the complete edition no longer writes appearance values this edition has no control for: they are skipped, and what your site already had is left alone.

= 1.0.21 =
* Spam turned away by the "send us a message" box is now counted in Analytics, as it already was for the emailed conversation copy. It used to be turned away silently.
* The prompt used to read your homepage is now written in English.

= 1.0.20 =
* Every fix from a full line-by-line review of the code was brought over from the paid edition. Among them: a price list restored from an exported configuration could make the public chat return a fatal error; the Bot name field froze on the first save; an unreadable API key was reported as working while the bot stayed silent.

**Version numbers between 1.0.12 and 1.0.19 belong to the separate paid edition and were never released here. Nothing has been removed from this list.**

The full history of this edition, from 1.0.8 onwards, is in `changelog.txt` inside the plugin folder.

== Upgrade Notice ==

= 1.0.27 =
The plugin links to its own product page instead of the site homepage.

= 1.0.26 =
Eight fixes from a full restaurant test: WooCommerce variants, night shifts, booking times, PDF logo and more.

= 1.0.25 =
Removes the Italian sample sentences the assistant could copy word for word into a reply.

= 1.0.24 =
Completes the language fix: the assistant no longer drifts into Italian because the instructions are written in Italian.

= 1.0.23 =
Fixes the bot ignoring your language settings: it now follows them from the customer's first message.

= 1.0.22 =
Adds Gemini 3.5 Flash-Lite and corrects the plan comparison, which understated what this free edition includes.
