|
|
--- |
|
|
license: apache-2.0 |
|
|
language: |
|
|
- en |
|
|
library_name: transformers |
|
|
tags: |
|
|
- advisory |
|
|
- llm-enhancement |
|
|
- crm |
|
|
- salesforce |
|
|
- decision-support |
|
|
base_model: Qwen/Qwen3-4B |
|
|
--- |
|
|
|
|
|
# ARC Advisor: Intelligent CRM Query Assistant for LLMs |
|
|
|
|
|
<div align="center"> |
|
|
|
|
|
 |
|
|
 |
|
|
 |
|
|
|
|
|
</div> |
|
|
|
|
|
## π Model Overview |
|
|
|
|
|
ARC Advisor is a specialized advisory model designed to enhance Large Language Models' performance on CRM and Salesforce-related tasks. By providing intelligent guidance and query structuring suggestions, it helps LLMs achieve significantly better results on complex CRM operations. |
|
|
|
|
|
### β¨ Key Benefits |
|
|
|
|
|
- **X% Performance Boost**: Improves LLM accuracy on CRM tasks when used as an advisor |
|
|
- **Intelligent Query Planning**: Provides structured approaches for complex Salesforce queries |
|
|
- **Error Prevention**: Identifies potential pitfalls before query execution |
|
|
- **Cost Efficient**: Small 4B model provides guidance to larger models, reducing overall compute costs |
|
|
|
|
|
## π― Use Cases |
|
|
|
|
|
### 1. LLM Performance Enhancement |
|
|
Boost your existing LLM's CRM capabilities by using ARC Advisor as a preprocessing step: |
|
|
|
|
|
```python |
|
|
from transformers import AutoModelForCausalLM, AutoTokenizer |
|
|
|
|
|
# Load ARC Advisor |
|
|
advisor = AutoModelForCausalLM.from_pretrained("aman-jaglan/arc-advisor") |
|
|
tokenizer = AutoTokenizer.from_pretrained("aman-jaglan/arc-advisor") |
|
|
|
|
|
def enhance_llm_query(user_request): |
|
|
# Step 1: Get advisory guidance |
|
|
advisor_prompt = f"""As a CRM expert, provide guidance for this request: |
|
|
{user_request} |
|
|
|
|
|
Suggest the best approach, relevant objects, and query structure.""" |
|
|
|
|
|
inputs = tokenizer(advisor_prompt, return_tensors="pt") |
|
|
advice = advisor.generate(**inputs, max_new_tokens=200) |
|
|
|
|
|
# Step 2: Use advice to enhance main LLM prompt |
|
|
enhanced_prompt = f""" |
|
|
Expert Guidance: {tokenizer.decode(advice[0])} |
|
|
|
|
|
Now execute: {user_request} |
|
|
""" |
|
|
|
|
|
return enhanced_prompt |
|
|
``` |
|
|
|
|
|
### 2. Query Optimization |
|
|
Transform vague requests into structured CRM queries: |
|
|
|
|
|
- **Input**: "Show me our best customers from last quarter" |
|
|
- **ARC Advisor Output**: Structured approach with relevant Salesforce objects, filters, and aggregations |
|
|
- **Result**: Precise SOQL query with proper date ranges and metrics |
|
|
|
|
|
### 3. Multi-Step Reasoning |
|
|
Guide LLMs through complex multi-object queries: |
|
|
|
|
|
- Lead-to-Opportunity conversion analysis |
|
|
- Cross-object relationship queries |
|
|
- Time-based trend analysis |
|
|
- Performance metric calculations |
|
|
|
|
|
## π οΈ Integration Examples |
|
|
|
|
|
### With OpenAI GPT Models |
|
|
```python |
|
|
import openai |
|
|
|
|
|
# Get advisor guidance first |
|
|
advice = get_arc_advisor_guidance(query) |
|
|
|
|
|
# Enhanced GPT query |
|
|
response = openai.ChatCompletion.create( |
|
|
model="gpt-4", |
|
|
messages=[ |
|
|
{"role": "system", "content": f"CRM Expert Guidance: {advice}"}, |
|
|
{"role": "user", "content": original_query} |
|
|
] |
|
|
) |
|
|
``` |
|
|
|
|
|
### With Local LLMs (vLLM) |
|
|
```python |
|
|
# Deploy ARC Advisor on lightweight infrastructure |
|
|
# Use output to guide larger local models |
|
|
advisor_server = "http://localhost:8000/v1/chat/completions" |
|
|
main_llm_server = "http://localhost:8001/v1/chat/completions" |
|
|
``` |
|
|
|
|
|
## π Performance Impact |
|
|
|
|
|
When used as an advisor: |
|
|
- **Query Success Rate**: +X% improvement |
|
|
- **Complex Query Handling**: +X% accuracy boost |
|
|
- **Error Reduction**: X% fewer malformed queries |
|
|
- **Time to Solution**: X% faster query resolution |
|
|
|
|
|
## π§ Deployment |
|
|
|
|
|
### Quick Start |
|
|
```bash |
|
|
# Using Transformers |
|
|
from transformers import pipeline |
|
|
advisor = pipeline("text-generation", model="aman-jaglan/arc-advisor") |
|
|
|
|
|
# Using vLLM (recommended for production) |
|
|
python -m vllm.entrypoints.openai.api_server \ |
|
|
--model aman-jaglan/arc-advisor \ |
|
|
--dtype bfloat16 \ |
|
|
--max-model-len 4096 |
|
|
``` |
|
|
|
|
|
### Resource Requirements |
|
|
- **GPU Memory**: 8GB (bfloat16) |
|
|
- **CPU**: Supported with reduced speed |
|
|
- **Optimal Batch Size**: 32-64 requests |
|
|
|
|
|
## π Why ARC Advisor? |
|
|
|
|
|
1. **Specialized Expertise**: Trained specifically for CRM/Salesforce domain |
|
|
2. **Efficient Architecture**: Small model that enhances larger models |
|
|
3. **Production Ready**: Optimized for low-latency advisory generation |
|
|
4. **Cost Effective**: Reduce expensive LLM calls through better query planning |
|
|
|
|
|
## π Model Details |
|
|
|
|
|
- **Architecture**: Qwen3-4B base with specialized fine-tuning |
|
|
- **Context Length**: 4096 tokens |
|
|
- **Output Format**: Structured advisory guidance |
|
|
- **Language**: English |
|
|
|
|
|
## π€ Community |
|
|
|
|
|
Join our community to share your experiences and improvements: |
|
|
- Report issues on the [model repository](https://huggingface.co/aman-jaglan/arc-advisor) |
|
|
- Share your integration examples |
|
|
- Contribute to best practices documentation |
|
|
|
|
|
## π License |
|
|
|
|
|
Apache 2.0 - Commercial use permitted with attribution |
|
|
|
|
|
--- |
|
|
|
|
|
*Transform your LLM into a CRM expert with ARC Advisor* |