Mozilla AI Guide Launch with Summarization Code Example
Mozilla's AI Guide launches as a community resource for developers new to AI, starting with LLM basics and a section on choosing open models. A worked example shows how to pick an open summarization model: use Hugging Face to list candidates, then Papers With Code to find the most-cited dataset (CNN/DailyMail), vet its license and provenance, and compare models on ROUGE-1/2/L for abstractive summarization. Google's Pegasus fine-tuned on CNN/DailyMail is then run locally with Hugging Face Transformers. Experiments with max_new_tokens, temperature, top_k and top_p sampling show how decoding settings change summary length and quality.
Related posts
- Investing in Performance: Fine-tune small models with LLM insights - a CFM case study
Hugging Face mediumAdeptCapital Fund Management built a financial named-entity recognition pipeline that extracts company names from Benzinga news headlines in the FNSPID dataset. Llama 3.1-70B, served on Hugging Face Inference Endpoints, pre-labels the headlines using a structured few-shot prompt and JSON-schema guided output, and humans then review those labels in Argilla. Fine-tuning compact models such as GLiNER and SpanMarker on the curated labels raises F1 to 93.4% and 90.1%. That approaches the 95% zero-shot F1 of Llama 3.1-70B at up to 80x lower inference cost. The walkthrough includes endpoint setup, prompt design, async batched requests with AsyncInferenceClient, and a comparison against weak supervision.
- From OpenAI to Open LLMs with Messages API on Hugging Face
Hugging Face mediumAdeptText Generation Inference 1.4.0 adds a Messages API compatible with OpenAI's Chat Completion API, so open LLMs on Inference Endpoints can be called from existing OpenAI client code by changing the base URL and token. The guide deploys Nous-Hermes-2-Mixtral-8x7B-DPO via huggingface_hub with TGI token-limit settings and then calls it from the OpenAI Python and JavaScript clients. It also plugs the endpoint into LangChain (ChatOpenAI) and LlamaIndex (OpenAILike) RAG pipelines. Limitations: no function calling, only models with a chat_template, and a subset of parameters (stream, max_tokens, temperature, top_p, seed, logprobs, frequency_penalty).
- Welcome GPT OSS, the new open-source model family from OpenAI!
Hugging Face mediumAdeptOpenAI's gpt-oss-120b (117B total, 5.1B active) and gpt-oss-20b (21B total, 3.6B active) are Apache 2.0 open-weight mixture-of-experts reasoning models. Their MoE weights are quantized to MXFP4, so the large model fits on one 80GB H100 and the small one runs in 16GB. Architecture notes cover softmax-after-topk routing, alternating full and 128-token sliding-window attention, and learned per-head attention sinks. The guide shows how to run the models via Inference Providers, transformers (MXFP4 kernels, Flash Attention 3 with sinks on Hopper, MegaBlocks MoE kernels as a bf16 fallback), llama.cpp and vLLM, plus fine-tuning with TRL and chat template handling.
- Open-source LLMs as LangChain Agents
Hugging Face mediumAdeptOpen-source LLMs can now serve as reasoning engines for tool-using ReAct agents, with Mixtral-8x7B outperforming GPT-3.5 out of the box on a mixed benchmark drawn from HotpotQA, GSM8K and GAIA, graded by GPT-4-as-a-judge. The ReAct loop works by prompting for a Thought plus a JSON tool call or a Final Answer, then parsing the output, running the tool and appending the Observation to the prompt. Agents are built in LangChain with the new ChatHuggingFace wrapper. Llama2-70b and Zephyr-7b perform poorly. About 10% of Mixtral's GAIA failures come from malformed tool arguments, so fine-tuning for function calling is the recommended next step. Giving models a calculator lifts zero-shot GSM8K scores, though only 20 questions were tested.
- Open-source DeepResearch – Freeing our search agents
Hugging Face mediumAdeptHugging Face reproduced OpenAI's Deep Research agent in about 24 hours using the open smolagents framework and reached 55.15% on the GAIA validation set, up from roughly 46% for the previous open state of the art (Magentic-One). OpenAI reports 67.36%. Most of the gain comes from a CodeAgent that writes its actions as Python code instead of JSON tool calls. Swapping in JSON actions on the same setup drops the score to 33%. Code actions need about 30% fewer steps and tokens and handle multimodal state more easily. The toolset is deliberately simple: a text-based web browser and a file inspector borrowed from Magentic-One. Next steps are vision-based GUI browsing and benchmarking open models such as DeepSeek R1.