Dataset
Code-switching speech datasets for AI training
A code-switching speech dataset is a collection of recorded conversations in which speakers move between two languages inside a call or a sentence, such as Hindi and English or Spanish and English, with transcripts that carry word-level language tags and marked switch points. SourceX sources these to a buyer's spec from established businesses whose ordinary call and broadcast archives hold them, such as bilingual-market contact centers, regional media companies and sales teams. Each dataset is de-identified and licensed for an agreed permitted use.
Dataset manifest
Sourced to your spec- What it is
- Real bilingual conversations with word-level language tags and marked switch points
- Typical systems
- Contact center recorders such as Genesys Cloud, NICE CXone and Amazon Connect; broadcast archives
- Typical history
- Specified by the buyer; limited by recording retention in each archive
- Modality
- Conversational audio with tagged transcripts in a stated script convention
- Delivery formats
- Agreed per order; typically WAV or FLAC with JSONL, TextGrid or ELAN transcripts and the guideline
- Preparation
- Speakers pseudonymized; personal data spoken in either language redacted in audio and transcript
- Licensing
- Rights reviewed against recording consent in each jurisdiction; permitted use set in the license
- Availability
- Sourced to your spec; supply is not guaranteed and depends on language pair and market
What a delivery contains
Fields vary by source system and are fixed per order. A typical delivery includes:
| Field | Type | What it holds |
|---|---|---|
| recording_id | string | Pseudonymous ID for one call or broadcast segment, shared by audio and transcript layers. |
| language_pair | object | The two languages as BCP 47 tags, with the base language of the conversation where one dominates. |
| source_context | object | Setting, line of business, the single-language label the archive gave the recording and the agent's routing languages. |
| media | object | Audio file reference with channel layout, codec and sample rate. |
| script_convention | object | Script used for each language, any romanization scheme and the guideline version the transcriber followed. |
| lang_tag_scheme | array | The token tag set in use, covering both languages, mixed words, named entities, borrowings, ambiguous words and other. |
| utterances | array | Speaker-attributed utterances with start and end times. |
| utterances[].tokens | array | Each word as written, with its language tag and, where aligned, its own times. |
| utterances[].switch_points | array | Positions where the language changes, each typed as inside a sentence, between sentences or a tag phrase. |
| utterances[].switch_density | object | Switch points per word boundary, computed with borrowed words counted each way. |
| utterances[].parallel_forms | object | Alternative renderings, such as a romanized or native-script version, mapped token by token. |
| borrowing_list | object | Version of the loanword list applied and the entries that occur in the recording. |
| tag_agreement | object | Agreement between annotators on token tags for the double-tagged sample this recording belongs to. |
| pii_spans | array | Redacted spans with time range, type and the language the detail was spoken in, matched in audio and text. |
Field names from the table above; values are masked placeholders.
Example record
{
"recording_id": "cs_90b3a7",
"language_pair": { "base": "hi", "embedded": "en" },
"source_context": { "setting": "contact_center", "line_of_business": "consumer_lending", "archive_language_label": "Hindi",
"agent_routing_languages": ["hi", "en"] },
"media": { "file": "cs_90b3a7.wav", "channels": 2, "sample_rate_hz": 8000 },
"script_convention": { "hi": "Deva", "en": "Latn", "guideline_version": "2.1" },
"lang_tag_scheme": ["hi", "en", "mixed", "ne", "borrowed", "ambiguous", "other"],
"utterances": [
{ "utt": 14, "speaker": "customer", "start_s": 71.42, "end_s": 74.9,
"tokens": [
{ "w": "मेरी", "lang": "hi" }, { "w": "EMI", "lang": "borrowed" }, { "w": "की", "lang": "hi" },
{ "w": "due", "lang": "en" }, { "w": "date", "lang": "en" }, { "w": "change", "lang": "en" },
{ "w": "हो", "lang": "hi" }, { "w": "सकती", "lang": "hi" }, { "w": "है", "lang": "hi" }, { "w": "क्या", "lang": "hi" }
],
"switch_points": [ { "after_token": 2, "type": "intra_sentential" }, { "after_token": 5, "type": "intra_sentential" } ],
"switch_density": { "borrowings_as_base": 0.22, "borrowings_as_embedded": 0.44 },
"parallel_forms": { "romanized": "meri EMI ki due date change ho sakti hai kya" } }
],
"borrowing_list": { "version": "1.3", "entries_used": ["EMI"] },
"tag_agreement": { "sample": "double_tagged", "token_agreement": 0.94 },
"pii_spans": [ { "utt": 15, "start_s": 76.1, "end_s": 79.8, "type": "loan_account_number",
"spoken_in": "en", "audio": "tone", "text": "[ACCOUNT_NUMBER]" } ]
}Synthetic record for illustration. Field names, structure and format are agreed per order.
What AI teams use it for
Train recognition that survives the switch
Real mixed utterances teach a recognizer to keep decoding when one voice changes language mid-phrase.
Identify language word by word
Token tags over audio train spoken language identification at a finer grain than one label per file.
Build voice agents for bilingual markets
Service calls show how customers actually phrase requests when they mix languages, and how human agents follow.
Evaluate by switch density
Held-out sets binned by density show whether accuracy falls as mixing gets heavier, which an average hides.
Train transliteration and normalization
Mapped native-script and romanized layers give pairs for converting between the forms people speak, type and read.
Use-case guides: Voice agents and speech models, Customer support agents, Private evaluation sets
What makes this data valuable
Switches inside sentences
A stated share of utterances with a switch inside the sentence separates real mixing from two monolingual halves.
One written convention
Every transcript follows the same script and spelling rules, and the guideline version is on each record.
Tags on every word
Language is labeled per token with a documented tag set, not per call or per utterance.
Borrowing list delivered
The loanword list and the rule behind it ship with the data, so densities can be recomputed.
Agreement reported
Annotator agreement on token tags is measured on a double-tagged sample and broken out by tag.
Many distinct speakers
Speech is spread across many customers and agents, with a cap on any one agent's share.
Call to transcript
Code-switched speech
Code-switching cannot be scripted convincingly
Bilingual speakers do not switch languages at random. They tend to switch where the grammars of both languages allow it, more often with listeners who share both, and for a reason: a product term, a number, a quoted remark, a change of tone. Ask a speaker to read a mixed sentence, or to "use both languages", and the result is staged. Switches tend to land on single nouns at even intervals, and the delivery is read speech. Text made by swapping words into a sentence often breaks the grammar. Audio spliced from two monolingual synthetic voices changes speaker at every switch, when a real speaker keeps one voice and carries the sounds of one language into the other.
The real thing sits in ordinary business archives. In a Hindi service call the agent often opens formally, the customer answers in a mix, and the agent follows. Amounts, dates and banking terms often come out in English inside Hindi sentences. Spanish and English mix the same way on bilingual service and sales lines and on regional call-in radio. None of it is labeled as mixed. The archive's language field is usually the queue or the menu option the caller pressed, so mixed calls have to be found by listening or by a language-identification pass. A platform transcript made by a recognizer set to one language tends to be wrong at exactly the switches.
The figure to request is switch density per utterance: the number of points where the language changes, divided by the number of word boundaries. Ask for it as a distribution, with the share of utterances wholly in each language and the split between switches inside a sentence and between sentences. A corpus-wide share of English words cannot tell alternating monolingual sentences from dense mixing. Published measures include the Code-Mixing Index and the switch-point fraction, and formulas differ between papers, so ask which was used. Ask how calls were selected, since mining with a language detector favors calls the detector handles well.
The transcript convention is the deliverable
Two transcribers can hear the same mixed sentence perfectly and write it three ways. For Hindi and English the choices are Hindi in Devanagari with English in Latin letters, everything in Latin letters the way people type messages, or everything in Devanagari with English words spelled by sound. Romanized Hindi has no standard spelling, so one word turns up as "nahi", "nahin" and "nahee". A corpus that mixes conventions shows a model the same spoken word in several written forms and scores correct recognition as an error. Research on this pair has used a transliterated word error rate, which accepts an English word in either script, for that reason.
Word-level language tags carry the rest. Spanish and English share an alphabet, so nothing on the page marks a switch, and "no" is a word in both. A usable tag set has the two languages plus tags for named entities, words built from both languages, ambiguous words and everything else, as the research benchmarks for this task do. Script should be stated per language with standard codes, so that Hindi in Latin letters can be told from Hindi in Devanagari, and a mapping between the forms should ship with the data so one corpus can be scored either way.
Borrowed words decide what the numbers mean. "Bus", "ticket" and "bank" are everyday Hindi, and nobody switches languages to say them. Tag them as English and switch density rises with no change in the speech: in this page's example record one borrowed word moves an utterance from two switch points to four. A language-identification model trained on those tags can learn that every modern noun is foreign. Tag them as Hindi and the guideline needs a rule for where borrowing ends, plus a list. Either choice works if it is written down, applied by annotators who agree with each other on a double-tagged sample, and reported both ways. Without the guideline, the list and the agreement figure, nobody can say what the tags mean.
What to check before licensing
- Have counsel confirm call-recording consent for every jurisdiction involved, including the caller's location and the contact center's, which are often in different states or countries.
- Check on a sample that names, numbers and addresses are redacted whichever language they were spoken in, in the audio and in every transcript layer, including a romanized one.
- Ask for the transcription guideline, its version history and the borrowing list, and reject a delivery that mixes script conventions without marking them.
- Recompute switch density on the sample under your own rule for borrowed words and compare it with the figure in the manifest.
- Ask who transcribed and tagged: bilingual annotators working from audio, or a recognizer's output corrected afterward, and what share was double-tagged.
- Count speakers as well as hours. A few agents can account for much of the speech, and an employer's language policy shapes how they switch.
- Ask how mixed recordings were selected from the archive and what share of all recordings they were, so you know what the selection left out.
Delivery No files move before a signed license. A listing or a request grants no files by itself.
How licensing works through SourceX
- 1
Define
Send the domain, modality, volume, format, timeline and permitted use you need.
- 2
Source
SourceX identifies businesses that hold matching data and are open to licensing it.
- 3
Qualify
Fit, rights and quality are checked, and you review samples before committing.
- 4
License
Scope, permitted use, exclusivity, price and obligations are agreed in writing.
- 5
Deliver
Approved data is prepared, de-identified where required and transferred securely.
Questions Acquisition Partners ask
How is code-switched speech different from a multilingual speech dataset?
A multilingual dataset holds separate recordings in separate languages. A code-switched dataset holds speakers using two languages inside one conversation, often inside one sentence. Models trained only on the first kind tend to fail at the switch, because they have not heard one voice change language mid-phrase. The labels differ too: language is tagged per word, not per file.
Which language pairs can be requested?
Any pair you specify, with no promise that a match exists. Supply follows business reality. Mixed speech is common where bilingual customers phone bilingual staff, as on Hindi and English or Spanish and English service lines, and in regional broadcast. State the pair, the region, the setting and whether one language must be the base of the sentence.
What switch density should I ask for?
Ask for a distribution and not a single average. Specify the share of utterances that must contain a switch inside the sentence, a floor on switch points per word boundary for those utterances, and how borrowed words are counted. Keep some monolingual utterances from the same speakers, since a model also has to learn when no switch is coming.
Should Hindi be transcribed in Devanagari or in Latin letters?
Decide by what your model should output, and decide before transcription starts. Native script for each language leaves a visible cue at every switch and matches formal text. Romanized Hindi matches how people type but has no fixed spelling, so it needs a spelling list. A common request is native script as the primary layer with a mapped romanized layer.
How are borrowed words and names tagged?
By a written rule that you should require with the data. A common rule gives established loanwords their own tag, or assigns them to the base language from a maintained list that is delivered with the corpus. Names of people, brands and places get a named-entity tag, because they belong to neither language. Ask for annotator agreement on these categories, where disagreement tends to be highest.
How is personal data handled when it is spoken in two languages?
It is removed or masked in audio and transcript whichever language it was spoken in, and the method is recorded. Mixed speech is hard on redaction tools built for one language: a name can sit in a Hindi sentence while the account number after it is read in English. No method is perfect, so ask for bilingual review of redaction and check a sample yourself.
Related datasets
- Multilingual conversational speech
Unscripted two-party conversations per language, with verbatim transcripts, turns and speaker metadata
- Accented and dialect speech with transcripts
New recordings of one language across regional and non-native varieties, with transcripts and speaker labels
- Low-resource language speech
Speech in one under-resourced language per delivery, with transcripts and a written orthography guideline
- Contact center call recordings and transcripts
Recorded service and support calls with diarized transcripts, dispositions and QA scores
- Human-verified audio transcripts with word-level timestamps
Audio with human-produced or human-corrected transcripts, word start and end times, speaker turns and the style guide
Evaluating this data for procurement?
Diligence packets are prepared per dataset. Rights, privacy processing and quality differ between datasets.
Request dataset diligenceTell us what your models need
Send your spec — domain, volume, format, timeline and permitted use — and SourceX will match it against partner data and come back with what can be licensed.
Updated 25 November 2026.