@ -0,0 +1,132 @@ |
|||
# Ora-Ai Website for Odoo 18 |
|||
|
|||
[](https://www.odoo.com) |
|||
[](https://opensource.org/licenses/MIT) |
|||
|
|||
## Overview |
|||
|
|||
This module facilitates order placement via ora AI voice assistance, |
|||
seamlessly integrating with the Sale Order system to enhance customer service and streamline operations. |
|||
|
|||
## Features |
|||
|
|||
- ⏱️**Reducing Order Time.** |
|||
- 🎙️**Replacing Employees with Voice Assistance.** |
|||
- 🕒**24/7 Availability.** |
|||
- 🛒**Automated Sale Order Creation.** |
|||
- 🌐**Starts in English, then auto-detects and switches |
|||
to your default language set in the voice assistant.** |
|||
- 🧅**Addon Product Options and Variants.** |
|||
- 📢**Promotional Content Integration.** |
|||
|
|||
## Screenshots |
|||
|
|||
Here are some glimpses of ORA AI: |
|||
|
|||
### VAPI AI Interface |
|||
|
|||
<div> |
|||
<tr> |
|||
<td align="center"> |
|||
<img src="static/description/assets/screenshots/aa.png" alt="Feature 1" width="500" style="border: none;"/> |
|||
</td> |
|||
</tr> |
|||
</div> |
|||
|
|||
### Voice Assistance Interface |
|||
|
|||
<div> |
|||
<tr> |
|||
<td align="center"> |
|||
Clicking the icon allows us to communicate with the assistants directly from the website. |
|||
<img src="static/description/assets/screenshots/ora_7.png" alt="Feature 1" width="500" style="border: none;border-radius: 5px;"/> |
|||
</td> |
|||
</tr> |
|||
</div> |
|||
<div> |
|||
<tr> |
|||
<td align="center"> Once you’ve selected the product and quantity, just confirm the order to add it to |
|||
your cart. |
|||
<img src="static/description/assets/screenshots/ora_8.png" alt="Feature 1" width="500" style="border: none;border-radius: 5px;"/> |
|||
</td> |
|||
</tr> |
|||
</div> |
|||
<div> |
|||
<tr> |
|||
<td align="center">The corresponding sales order has been created. We can now proceed with the |
|||
remaining confirmation steps. |
|||
<img src="static/description/assets/screenshots/ora_11.png" alt="Feature 1" width="500" style="border: none;border-radius: 5px;"/> |
|||
</td> |
|||
</tr> |
|||
</div> |
|||
|
|||
## Prerequisites |
|||
|
|||
Before you begin, ensure you have the following installed: |
|||
|
|||
- An active Odoo Community/Enterprise Edition instance (local or hosted) |
|||
|
|||
## Configuration |
|||
|
|||
- Once installed, users will be able to add the API details for VAPI AI. |
|||
Company |
|||
|
|||
## Installation |
|||
|
|||
Follow these steps to set up and run the app: |
|||
|
|||
1. **Clone the Repository** |
|||
|
|||
```git clone https://github.com/cybrosystech/Ora-AI-Voice.git``` |
|||
|
|||
2. **Add the module to addons** |
|||
|
|||
```cd Ora AI``` |
|||
|
|||
## Contributing |
|||
|
|||
We welcome contributions! To get started: |
|||
|
|||
1. Fork the repository. |
|||
|
|||
2. Create a new branch: |
|||
``` |
|||
git checkout -b feature/your-feature-name |
|||
``` |
|||
3. Make changes and commit: |
|||
``` |
|||
git commit -m "Add your message here" |
|||
``` |
|||
4. Push your changes: |
|||
``` |
|||
git push origin feature/your-feature-name |
|||
``` |
|||
5. Create a Pull Request on GitHub. |
|||
|
|||
--- |
|||
|
|||
- Submit a pull request with a clear description of your changes. |
|||
|
|||
## License |
|||
|
|||
This project is licensed under the AGPL-3. Feel free to use, modify, and distribute it as needed. |
|||
|
|||
Company |
|||
------- |
|||
|
|||
* `Cybrosys Techno Solutions <https://cybrosys.com/>` |
|||
|
|||
## Contact |
|||
|
|||
* Mail Contact : odoo@cybrosys.com |
|||
* Website : https://cybrosys.com |
|||
|
|||
|
|||
Maintainer |
|||
========== |
|||
 |
|||
https://cybrosys.com |
|||
|
|||
|
|||
This module is maintained by Cybrosys Technologies. |
|||
For support and more information, please visit https://www.cybrosys.com |
|||
@ -0,0 +1,23 @@ |
|||
# -*- coding: utf-8 -*- |
|||
############################################################################# |
|||
# |
|||
# Cybrosys Technologies Pvt. Ltd. |
|||
# |
|||
# Copyright (C) 2025-TODAY Cybrosys Technologies(<https://www.cybrosys.com>) |
|||
# Author: Cybrosys Techno Solutions(<https://www.cybrosys.com>) |
|||
# |
|||
# You can modify it under the terms of the GNU AFFERO |
|||
# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. |
|||
# |
|||
# This program is distributed in the hope that it will be useful, |
|||
# but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. |
|||
# |
|||
# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE |
|||
# (AGPL v3) along with this program. |
|||
# If not, see <http://www.gnu.org/licenses/>. |
|||
# |
|||
############################################################################# |
|||
from . import controllers |
|||
from . import models |
|||
@ -0,0 +1,53 @@ |
|||
# -*- coding: utf-8 -*- |
|||
############################################################################# |
|||
# |
|||
# Cybrosys Technologies Pvt. Ltd. |
|||
# |
|||
# Copyright (C) 2025-TODAY Cybrosys Technologies(<https://www.cybrosys.com>) |
|||
# Author: Cybrosys Techno Solutions(<https://www.cybrosys.com>) |
|||
# |
|||
# You can modify it under the terms of the GNU AFFERO |
|||
# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. |
|||
# |
|||
# This program is distributed in the hope that it will be useful, |
|||
# but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. |
|||
# |
|||
# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE |
|||
# (AGPL v3) along with this program. |
|||
# If not, see <http://www.gnu.org/licenses/>. |
|||
# |
|||
############################################################################# |
|||
{ |
|||
'name': 'Ora-Ai Website', |
|||
'version': '18.0.1.0.0', |
|||
'category': 'eCommerce', |
|||
'summary': """Ora-AI Website enables users to place product orders using |
|||
the voice assistant directly through the website.""", |
|||
'description': """Ora Website Assistant,By implementing this module |
|||
voice-activated technology, your customers can easily browse your eCommerce |
|||
store, inquire about products, and place orders, all by speaking naturally |
|||
to the AI.""", |
|||
'author': 'Cybrosys Techno Solutions', |
|||
'company': 'Cybrosys Techno Solutions', |
|||
'maintainer': 'Cybrosys Techno Solutions', |
|||
'website': 'https://www.cybrosys.com', |
|||
'depends': ['base', 'ora_ai_base', 'website_sale'], |
|||
'data': [ |
|||
'views/res_config_settings_views.xml', |
|||
'views/templates.xml', |
|||
'views/website_menus.xml', |
|||
], |
|||
'assets': { |
|||
'web.assets_frontend': [ |
|||
'ora_ai_website/static/src/js/website_templates.js', |
|||
'ora_ai_website/static/src/scss/website_template.scss', |
|||
], |
|||
}, |
|||
'images': ['static/description/banner.jpg'], |
|||
'license': 'AGPL-3', |
|||
'auto_install': False, |
|||
'installable': True, |
|||
'application': False |
|||
} |
|||
@ -0,0 +1,22 @@ |
|||
# -*- coding: utf-8 -*- |
|||
############################################################################# |
|||
# |
|||
# Cybrosys Technologies Pvt. Ltd. |
|||
# |
|||
# Copyright (C) 2025-TODAY Cybrosys Technologies(<https://www.cybrosys.com>) |
|||
# Author: Cybrosys Techno Solutions(<https://www.cybrosys.com>) |
|||
# |
|||
# You can modify it under the terms of the GNU AFFERO |
|||
# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. |
|||
# |
|||
# This program is distributed in the hope that it will be useful, |
|||
# but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. |
|||
# |
|||
# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE |
|||
# (AGPL v3) along with this program. |
|||
# If not, see <http://www.gnu.org/licenses/>. |
|||
# |
|||
############################################################################# |
|||
from . import ora_ai_website |
|||
@ -0,0 +1,132 @@ |
|||
# -*- coding: utf-8 -*- |
|||
############################################################################# |
|||
# |
|||
# Cybrosys Technologies Pvt. Ltd. |
|||
# |
|||
# Copyright (C) 2025-TODAY Cybrosys Technologies(<https://www.cybrosys.com>) |
|||
# Author: Cybrosys Techno Solutions(<https://www.cybrosys.com>) |
|||
# |
|||
# You can modify it under the terms of the GNU AFFERO |
|||
# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. |
|||
# |
|||
# This program is distributed in the hope that it will be useful, |
|||
# but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. |
|||
# |
|||
# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE |
|||
# (AGPL v3) along with this program. |
|||
# If not, see <http://www.gnu.org/licenses/>. |
|||
# |
|||
############################################################################# |
|||
from odoo import fields, http |
|||
from odoo.http import request, route |
|||
|
|||
|
|||
class WebSiteVapiController(http.Controller): |
|||
"""This controller handles various HTTP routes related to VAPI assistant |
|||
integration and product-related operations on the website.""" |
|||
|
|||
@route('/website_assistant', auth='public', type='json', |
|||
website=True) |
|||
def website_assistant_data(self): |
|||
"""Get the values from the settings and return as data dictionary. """ |
|||
private_api_key = request.env['ir.config_parameter'].sudo().get_param( |
|||
'ora_ai_base.vapi_private_api_key') |
|||
public_api_key = request.env['ir.config_parameter'].sudo().get_param( |
|||
'ora_ai_base.vapi_public_api_key') |
|||
assistant = request.env['ir.config_parameter'].sudo().get_param( |
|||
'ora_ai_website.website_assistant_id') |
|||
assistant_id = request.env['ora.ai'].sudo().browse( |
|||
int(assistant)).id_assistant |
|||
return {'public_api_key': public_api_key, |
|||
'assistant': assistant_id, |
|||
'private_api_key': private_api_key} |
|||
|
|||
@route('/get_product_id', auth='public', type='json', website=True) |
|||
def get_product_id(self, **args): |
|||
"""Fetch the corresponding product.""" |
|||
product = args.get('product_name') |
|||
product_id = request.env['product.product'].sudo().search( |
|||
[('name', '=', product)]) |
|||
return {'product_id': product_id.id} |
|||
|
|||
@route('/get_variant_product_id', auth='public', type='json', |
|||
website=True) |
|||
def get_variant_product_id(self, **args): |
|||
"""Fetch the product variant ID that matches the given product |
|||
name and variant attribute values.""" |
|||
variant = args.get('variant_name') |
|||
att_value_list = [var.strip() for var in variant.split(",")] |
|||
att_id_list = [] |
|||
for val in att_value_list: |
|||
att_id_list.append(request.env['product.attribute.value'].search( |
|||
[('name', '=', val)]).id) |
|||
product_variants = request.env['product.product'].search( |
|||
[('name', '=', args.get('product_name'))]) |
|||
variant_product_id = [] |
|||
for rec in product_variants: |
|||
variant_product_ids = rec.product_template_variant_value_ids.ids |
|||
variants = rec.product_template_variant_value_ids.mapped('name') |
|||
if (variant_product_ids == att_id_list or |
|||
variants == att_value_list): |
|||
variant_product_id.append(rec.id) |
|||
return { |
|||
'variant_product_id': variant_product_id[0] |
|||
} |
|||
|
|||
@route('/get_product_name', auth='public', type='json', website=True) |
|||
def get_product_name(self): |
|||
"""Getting all the published product names.""" |
|||
product_name = request.env['product.template'].sudo().search( |
|||
[('is_published', '=', True)]).mapped('name') |
|||
return {'product_name': product_name} |
|||
|
|||
@route('/shop/add_to_cart', auth='public', type='json', website=True) |
|||
def add_to_cart(self, products): |
|||
""" Add multiple products to the website cart.""" |
|||
order = request.website.sale_get_order( |
|||
force_create=1) |
|||
val = [] |
|||
for product_id_str, quantity in products.items(): |
|||
product_id = int(product_id_str) |
|||
view = request.env['ir.ui.view'] |
|||
values = order._cart_update(product_id=product_id, |
|||
add_qty=quantity) |
|||
values['website_sale.cart_lines'] = view._render_template( |
|||
"website_sale.cart_lines", { |
|||
'website_sale_order': order, |
|||
'date': fields.Date.today(), |
|||
'suggested_products': order._cart_accessories()}) |
|||
values['website_sale.total'] = view._render_template( |
|||
"website_sale.total", { |
|||
'website_sale_order': order}) |
|||
request.session['website_sale_cart_quantity'] = order.cart_quantity |
|||
values['cart_quantity'] = order.cart_quantity |
|||
val.append(values) |
|||
line_ids = [values['line_id']] |
|||
lines = order.order_line.filtered(lambda line: line.id in line_ids) |
|||
show_tax = order.website_id.show_line_subtotals_tax_selection == 'tax_included' |
|||
notification = { |
|||
'currency_id': order.currency_id.id, |
|||
'lines': [{'id': line.id, |
|||
'image_url': order.website_id.image_url( |
|||
line.product_id, 'image_128'), |
|||
'quantity': line.product_uom_qty, |
|||
'name': line.name_short, |
|||
'description': line._get_sale_order_line_multiline_description_variants(), |
|||
'line_price_total': ( |
|||
line.price_total |
|||
if show_tax |
|||
else line.price_subtotal |
|||
), |
|||
} for line in lines |
|||
], |
|||
} |
|||
values['notification_info'] = notification |
|||
return { |
|||
'success': True, |
|||
'order_id': order.id, |
|||
'order_total': order.amount_total, |
|||
'values': val, |
|||
} |
|||
@ -0,0 +1,7 @@ |
|||
## Module <ora_ai_website> |
|||
|
|||
#### 03.12.2025 |
|||
#### Version 18.0.1.0.0 |
|||
#### ADD |
|||
|
|||
- Initial commit for Ora-Ai Website |
|||
@ -0,0 +1,22 @@ |
|||
# -*- coding: utf-8 -*- |
|||
############################################################################# |
|||
# |
|||
# Cybrosys Technologies Pvt. Ltd. |
|||
# |
|||
# Copyright (C) 2025-TODAY Cybrosys Technologies(<https://www.cybrosys.com>) |
|||
# Author: Cybrosys Techno Solutions(<https://www.cybrosys.com>) |
|||
# |
|||
# You can modify it under the terms of the GNU AFFERO |
|||
# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. |
|||
# |
|||
# This program is distributed in the hope that it will be useful, |
|||
# but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. |
|||
# |
|||
# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE |
|||
# (AGPL v3) along with this program. |
|||
# If not, see <http://www.gnu.org/licenses/>. |
|||
# |
|||
############################################################################# |
|||
from .import res_config_settings |
|||
@ -0,0 +1,36 @@ |
|||
# -*- coding: utf-8 -*- |
|||
############################################################################# |
|||
# |
|||
# Cybrosys Technologies Pvt. Ltd. |
|||
# |
|||
# Copyright (C) 2025-TODAY Cybrosys Technologies(<https://www.cybrosys.com>) |
|||
# Author: Cybrosys Techno Solutions(<https://www.cybrosys.com>) |
|||
# |
|||
# You can modify it under the terms of the GNU AFFERO |
|||
# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. |
|||
# |
|||
# This program is distributed in the hope that it will be useful, |
|||
# but WITHOUT ANY WARRANTY; without even the implied warranty of |
|||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|||
# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. |
|||
# |
|||
# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE |
|||
# (AGPL v3) along with this program. |
|||
# If not, see <http://www.gnu.org/licenses/>. |
|||
# |
|||
############################################################################# |
|||
from odoo import fields, models |
|||
|
|||
|
|||
class ResConfigSettings(models.TransientModel): |
|||
"""Inherited to add the Website assistants fields in the settings.""" |
|||
_inherit = 'res.config.settings' |
|||
|
|||
is_website_assistant = fields.Boolean(string='Enable Website Assistant', |
|||
config_parameter='ora_ai_website.is_website_assistant', |
|||
help='Check this field for enabling ' |
|||
'Website assistant') |
|||
website_assistant_id = fields.Many2one('ora.ai', |
|||
string="Choose Assistant", |
|||
config_parameter='ora_ai_website.website_assistant_id', |
|||
domain="[('state', '=', 'done')]") |
|||
|
After Width: | Height: | Size: 418 KiB |
|
After Width: | Height: | Size: 1.1 KiB |
|
After Width: | Height: | Size: 210 KiB |
|
After Width: | Height: | Size: 209 KiB |
|
After Width: | Height: | Size: 109 KiB |
|
After Width: | Height: | Size: 495 B |
|
After Width: | Height: | Size: 1.0 KiB |
|
After Width: | Height: | Size: 624 B |
|
After Width: | Height: | Size: 136 KiB |
|
After Width: | Height: | Size: 214 KiB |
|
After Width: | Height: | Size: 36 KiB |
|
After Width: | Height: | Size: 3.6 KiB |
|
After Width: | Height: | Size: 310 B |
|
After Width: | Height: | Size: 929 B |
|
After Width: | Height: | Size: 1.3 KiB |
|
After Width: | Height: | Size: 3.3 KiB |
|
After Width: | Height: | Size: 1.4 KiB |
|
After Width: | Height: | Size: 17 KiB |
|
After Width: | Height: | Size: 542 B |
|
After Width: | Height: | Size: 576 B |
|
After Width: | Height: | Size: 733 B |
|
After Width: | Height: | Size: 4.3 KiB |
|
After Width: | Height: | Size: 1.2 KiB |
|
After Width: | Height: | Size: 4.0 KiB |
|
After Width: | Height: | Size: 1.7 KiB |
|
After Width: | Height: | Size: 383 KiB |
|
After Width: | Height: | Size: 2.2 KiB |
|
After Width: | Height: | Size: 911 B |
|
After Width: | Height: | Size: 1.1 KiB |
|
After Width: | Height: | Size: 1.2 KiB |
|
After Width: | Height: | Size: 1.2 KiB |
|
After Width: | Height: | Size: 600 B |
|
After Width: | Height: | Size: 673 B |
|
After Width: | Height: | Size: 2.0 KiB |
|
After Width: | Height: | Size: 462 B |
|
After Width: | Height: | Size: 2.1 KiB |
|
After Width: | Height: | Size: 926 B |
|
After Width: | Height: | Size: 9.0 KiB |
|
After Width: | Height: | Size: 23 KiB |
|
After Width: | Height: | Size: 7.0 KiB |
|
After Width: | Height: | Size: 878 B |
|
After Width: | Height: | Size: 1.2 KiB |
|
After Width: | Height: | Size: 653 B |
|
After Width: | Height: | Size: 800 B |
|
After Width: | Height: | Size: 905 B |
|
After Width: | Height: | Size: 189 KiB |
|
After Width: | Height: | Size: 4.3 KiB |
|
After Width: | Height: | Size: 839 B |
|
After Width: | Height: | Size: 1.7 KiB |
|
After Width: | Height: | Size: 5.9 KiB |
|
After Width: | Height: | Size: 1.6 KiB |
|
After Width: | Height: | Size: 34 KiB |
|
After Width: | Height: | Size: 26 KiB |
|
After Width: | Height: | Size: 3.8 KiB |
|
After Width: | Height: | Size: 23 KiB |
|
After Width: | Height: | Size: 1.9 KiB |
|
After Width: | Height: | Size: 2.3 KiB |
|
After Width: | Height: | Size: 427 B |
|
After Width: | Height: | Size: 627 B |
|
After Width: | Height: | Size: 1.1 KiB |
|
After Width: | Height: | Size: 1.2 KiB |
|
After Width: | Height: | Size: 988 B |
|
After Width: | Height: | Size: 3.7 KiB |
|
After Width: | Height: | Size: 5.0 KiB |
|
After Width: | Height: | Size: 875 B |
|
After Width: | Height: | Size: 1.2 KiB |
|
After Width: | Height: | Size: 439 B |
|
After Width: | Height: | Size: 80 KiB |
|
After Width: | Height: | Size: 3.2 KiB |
|
After Width: | Height: | Size: 565 B |
|
After Width: | Height: | Size: 26 KiB |
|
After Width: | Height: | Size: 43 KiB |
|
After Width: | Height: | Size: 1.4 KiB |
|
After Width: | Height: | Size: 4.0 KiB |
|
After Width: | Height: | Size: 38 KiB |
|
After Width: | Height: | Size: 4.3 KiB |
|
After Width: | Height: | Size: 781 KiB |
|
After Width: | Height: | Size: 87 KiB |
|
After Width: | Height: | Size: 751 KiB |
|
After Width: | Height: | Size: 712 KiB |
|
After Width: | Height: | Size: 816 KiB |
|
After Width: | Height: | Size: 725 KiB |
|
After Width: | Height: | Size: 517 B |
|
After Width: | Height: | Size: 513 B |
|
After Width: | Height: | Size: 106 KiB |
|
After Width: | Height: | Size: 741 KiB |
|
After Width: | Height: | Size: 450 KiB |
|
After Width: | Height: | Size: 123 KiB |
|
After Width: | Height: | Size: 193 KiB |
|
After Width: | Height: | Size: 41 KiB |
|
After Width: | Height: | Size: 72 KiB |
|
After Width: | Height: | Size: 75 KiB |