Veus disponibles

Script per mostrar noms visibles de totes les veus OneCore:

Get-ChildItem "HKLM:\SOFTWARE\Microsoft\Speech_OneCore\Voices\Tokens" | ForEach-Object {
    $keyPath = $_.PSPath
    $voiceProps = Get-ItemProperty -Path $keyPath

    # Cerquem DisplayName dins dels subvalors (per exemple, en-US, es-ES...)
    $subkeys = Get-ChildItem -Path $keyPath -ErrorAction SilentlyContinue

    $displayName = $null

    foreach ($subkey in $subkeys) {
        $subProps = Get-ItemProperty -Path $subkey.PSPath -ErrorAction SilentlyContinue
        if ($subProps.DisplayName) {
            $displayName = $subProps.DisplayName
            break
        }
    }

    [PSCustomObject]@{
        VoiceId = $_.PSChildName
        Name    = $displayName
        Path    = $keyPath
    }
}

PS C:\WINDOWS\system32> Get-ChildItem "HKLM:\SOFTWARE\Microsoft\Speech_OneCore\Voices\Tokens" | ForEach-Object {
>>     $keyPath = $_.PSPath
>>     $voiceProps = Get-ItemProperty -Path $keyPath
>>
>>     # Cerquem DisplayName dins dels subvalors (per exemple, en-US, es-ES...)
>>     $subkeys = Get-ChildItem -Path $keyPath -ErrorAction SilentlyContinue
>>
>>     $displayName = $null
>>
>>     foreach ($subkey in $subkeys) {
>>         $subProps = Get-ItemProperty -Path $subkey.PSPath -ErrorAction SilentlyContinue
>>         if ($subProps.DisplayName) {
>>             $displayName = $subProps.DisplayName
>>             break
>>         }
>>     }
>>
>>     [PSCustomObject]@{
>>         VoiceId = $_.PSChildName
>>         Name    = $displayName
>>         Path    = $keyPath
>>     }
>> }

VoiceId                 Name Path
-------                 ---- ----
MSTTS_V110_caES_Herena       Microsoft.PowerShell.Core\Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Speech_OneCore\Voices\Tokens\MSTTS_V110_caES_Herena
MSTTS_V110_deDE_HeddaM       Microsoft.PowerShell.Core\Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Speech_OneCore\Voices\Tokens\MSTTS_V110_deDE_HeddaM
MSTTS_V110_deDE_KatjaM       Microsoft.PowerShell.Core\Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Speech_OneCore\Voices\Tokens\MSTTS_V110_deDE_KatjaM
MSTTS_V110_deDE_StefanM      Microsoft.PowerShell.Core\Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Speech_OneCore\Voices\Tokens\MSTTS_V110_deDE_StefanM
MSTTS_V110_enGB_GeorgeM      Microsoft.PowerShell.Core\Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Speech_OneCore\Voices\Tokens\MSTTS_V110_enGB_GeorgeM
MSTTS_V110_enGB_HazelM       Microsoft.PowerShell.Core\Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Speech_OneCore\Voices\Tokens\MSTTS_V110_enGB_HazelM
MSTTS_V110_enGB_SusanM       Microsoft.PowerShell.Core\Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Speech_OneCore\Voices\Tokens\MSTTS_V110_enGB_SusanM
MSTTS_V110_enUS_DavidM       Microsoft.PowerShell.Core\Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Speech_OneCore\Voices\Tokens\MSTTS_V110_enUS_DavidM
MSTTS_V110_enUS_MarkM        Microsoft.PowerShell.Core\Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Speech_OneCore\Voices\Tokens\MSTTS_V110_enUS_MarkM
MSTTS_V110_enUS_ZiraM        Microsoft.PowerShell.Core\Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Speech_OneCore\Voices\Tokens\MSTTS_V110_enUS_ZiraM
MSTTS_V110_esES_HelenaM      Microsoft.PowerShell.Core\Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Speech_OneCore\Voices\Tokens\MSTTS_V110_esES_HelenaM
MSTTS_V110_esES_LauraM       Microsoft.PowerShell.Core\Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Speech_OneCore\Voices\Tokens\MSTTS_V110_esES_LauraM
MSTTS_V110_esES_PabloM       Microsoft.PowerShell.Core\Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Speech_OneCore\Voices\Tokens\MSTTS_V110_esES_PabloM


PS C:\WINDOWS\system32>

Add-Type -AssemblyName System.Speech
$synth = New-Object System.Speech.Synthesis.SpeechSynthesizer
$synth.GetInstalledVoices() | ForEach-Object {
    $_.VoiceInfo.Name
}

🔍 4. (Opcional) Llistar també les veus modernes (OneCore)

Aquestes veus (com Microsoft Aria, Microsoft Jenny) no apareixen amb System.Speech, però pots veure-les així:

powershellCopiaModificaGet-ChildItem "HKLM:\SOFTWARE\Microsoft\Speech_OneCore\Voices\Tokens" | ForEach-Object {
    $_.GetValue("")
}

sadsd

profile

Qwen3-235B-A22B

Perfecte! 🎉

Les veus que veus són les veus TTS (Text-to-Speech) instal·lades al teu Windows 11. I sí, les mantindras de forma estable al sistema sempre que no les desinstal·lis o restableixis el sistema a valors d’origen.


✅ Què vol dir això?

Les veus que tens actualment:

Microsoft Hazel Desktopen-GBFemeníAnglès del Regne Unit
Microsoft David Desktopen-USMasculíAnglès dels EUA
Microsoft Zira Desktopen-USFemeníAnglès dels EUA
Microsoft Hedda Desktopde-DEFemeníAlemany
Vocalizer Expressive Jordi Harpoca-ESMasculíCatalà (amb motor de tercers)

🧠 Aquestes veus són compatibles amb l’API clàssica (System.Speech.Synthesis) i poden ser utilitzades per programes com Narrador, Cortana, PowerShell, etc.


💾 Seran estables? Sí 👍

Publicat dins de Veus

🌟🌟 Instal·lar veus angleses (com les de Text-to-Speech o TTS) a Windows 11

Get-ChildItem "HKLM:\SOFTWARE\Microsoft\Speech_OneCore\Voices\Tokens" | ForEach-Object {
    $_.GetValue("")
}

Per instal·lar veus angleses (com les de Text-to-Speech o TTS) a Windows 11 mitjançant PowerShell, pots utilitzar el mètode de Add-WindowsCapability o mitjançant registres i eines COM, depenent de la versió de Windows i el tipus de veu (clàssica o de nova generació).

✅ Mètode 1: Instal·lar veus angleses amb Add-WindowsCapability

powershellCopiaModifica# Executar com a administrador

# Exemple per instal·lar veu anglesa dels EUA
--------------------------------------------------------------------------
Add-WindowsCapability -Online -Name "Language.Basic~~~en-US~0.0.1.0"
Add-WindowsCapability -Online -Name "Language.Speech~~~en-US~0.0.1.0"
Add-WindowsCapability -Online -Name "Language.TextToSpeech~~~en-US~0.0.1.0"


Aquest mètode funciona amb paquets de reconeixement de veu i sínt

Altres idiomes (en-GB, en-AU, etc.) també estan disponibles canviant en-US per l’identificador corresponent.

✅ Mètode 2: Afegeix l’idioma complet (amb TTS inclòs)

powershellCopiaModifica# Afegeix anglès dels EUA amb suport de veu
$LangList = New-WinUserLanguageList en-US
$LangList[0].Handwriting = $true
Set-WinUserLanguageList $LangList -Force

Això afegeix l’idioma, però per garantir que la veu estigui disponible, potser necessites reiniciar o obrir manualment la configuració perquè Windows acabi de descarregar els components.


🔄 Mètode avançat: Activar la veu al registre (només si ja està instal·lada)

powershellCopiaModifica# Exemple d'activació d'una veu anglesa si està instal·lada
Set-ItemProperty "HKLM:\SOFTWARE\Microsoft\Speech_OneCore\Voices\Tokens\TTS_MS_EN-US_ZIRA_11.0" -Name "411" -Value "Microsoft Zira"

🧪 Com llistar les veus disponibles

powershellCopiaModificaAdd-Type –AssemblyName System.Speech
$synth = New-Object System.Speech.Synthesis.SpeechSynthesizer
$synth.GetInstalledVoices() | Select-Object -ExpandProperty VoiceInfo | Format-Table Name, Culture

❗ Notes

  • Algunes veus modernes (com neural voices de Microsoft) només es poden utilitzar mitjançant serveis de núvol (Azure Cognitive Services).
  • Executa sempre el script amb permisos d’administrador.
  • Algunes veus poden necessitar connexió a Internet per descarregar-se després de la instal·lació.

Script PowerShell per guardar la llista de veus en un fitxer .txt

Add-Type -AssemblyName System.Speech
$synth = New-Object System.Speech.Synthesis.SpeechSynthesizer

# Ruta on es desarà el fitxer (escriptori de l'usuari actual)
$outputPath = [System.IO.Path]::Combine([Environment]::GetFolderPath("Desktop"), "Veus_Instal·lades.txt")

# Obtenir les veus i formatejar-les
$voicesInfo = $synth.GetInstalledVoices() | ForEach-Object {
    $voice = $_.VoiceInfo
    "Nom: $($voice.Name)`nIdioma: $($voice.Culture)`nGènere: $($voice.Gender)`nEdat: $($voice.Age)`nDescripció: $($voice.Description)`n---"
}

# Escriure-ho al fitxer
$voicesInfo | Out-File -FilePath $outputPath -Encoding UTF8

# Mostrar confirmació
Write-Output "Llista de veus desada a: $outputPath"

Nom: Microsoft Zira Desktop
Idioma: en-US
Gènere: Female
Edat: Adult

Descripció: Microsoft Zira Desktop – English (United States)

Nom: Microsoft Hazel Desktop
Idioma: en-GB
Gènere: Female
Edat: Adult

Descripció: Microsoft Hazel Desktop – English (Great Britain)

Nom: Microsoft Helena Desktop
Idioma: es-ES
Gènere: Female
Edat: Adult

Descripció: Microsoft Helena Desktop – Spanish (Spain)

Nom: Microsoft Hortense Desktop
Idioma: fr-FR
Gènere: Female
Edat: Adult

Descripció: Microsoft Hortense Desktop – French

Nom: Vocalizer Expressive Jordi Harpo 22kHz
Idioma: ca-ES
Gènere: Male
Edat: Adult

Descripció: Vocalizer Expressive Jordi Harpo 22kHz