QnA Markdown formatting gets lost on using Transalation API - qnamaker

I have been using Microsoft Translator API v3.0 which does not seem to work in my case.
The Translation actually appends spaces and the markdown gets scrambled. How to fix this?
Thanks,
deeepss

The ! indicates a sentence end, which is not what you want in this case.
You can escape the exclamation point to a tag like <exclamation>. Then it will be handled as a word in the context of the sentence.

Related

How can I make a VS Code language extension insert an indent after a line ending in a colon, as in Python?

The VS Code documentation has a clear if short explanation of how to do custom indentation, but doing this has no effect — whatever I put in the "indentationRules", it fails to match the simplest patterns, and it doesn't even stop the built-in indentation from working, it goes right on using the default indentation described in the link above. All the other bits of the language extension are working, it's not a general problem, it's specific to trying to get these indentation rules to work. I've tried to find examples to copy from the internet but with no success. (I found an example of a grammar for Python but the only mention of indentation in it was as a possible kind of error, which is puzzling.)
Thanks for your help.

Is there a way of using the <prosody> tag in SSML to adjust individual words without a pause (without using a post-processor)

When using the prosody tag in SSML with Google Cloud TTS, I cannot adjust the attributes of individual words without creating an unwanted pause.
The code below creates a lag between 'New' and 'Video'. It has been suggested that a postprocessor can remove these pauses, but I'd like to know if there's a way of doing it directly within the code itself?
<speak>
Hello, and welcome to this<prosody pitch="+3st">New</prosody>Video Tutorial.
</speak>
After testing, it appears there isn't a way of doing this using Google Cloud TTS. You can manually edit the sound file after generating it, but thay defeats the object of the exercise.
I don't have the cleanest answer, as what you are asking is not very supported. Prosody's pitch contour let's you change the tone of voice at different parts of the sentence.
Example of Prosody contour
<speak><prosody contour="(0%, +20Hz) (20%, +30%) (100%, +20%)"> Hello friends! </prosody></speak>
I am still playing around with this, but it seems like a tedious way of getting what you want done.
Using contour
contour takes a string of tuples "(%position in sentence, pitch adjustment) (..., ...)
I hope this helped and best of luck on your work!

Unwanted pauses when using <prosody> tag in SSML for TTS

I am writing and marking up spoken utterances for an VUI tool. We are using Google Cloud Wave-net for our TTS service, and I have been trying to use SSML to make the TTS output more natural. When I add the tag "prosody", the TTS output adds a pause before the start of the tag, as in the below:
<speak>
Rebecca is allergic to <prosody rate="slow" range="high">soybean oil.</prosody> Would you like to cancel this order?
</speak>
In this example, the TTS output pauses between "to" and "soybean oil". This is just a silly example sentence, but in our real product we need to use this kind of tag to provide emphasis and differentiation between complex words.
Has anyone else experienced this issue? Any tips?
It looks like range isn't part of the Google Cloud TTS ssml spec. It is part of Microsoft's spec though, so maybe that's what you were thinking of.
If you're still trying to get rid of a gap like that, you could theoretically use the <seq> tag to get the segments to slightly overlap, but that seems like it'd be super difficult.

Is there a syntax to specify multiline code snippets in Google (Hangouts) Chat?

I would like something like the Markdown options (of SO?), where
four leading spaces makes it look like code
blocks have been written
Google (Hangouts) Chat only supports basic (not rich nor full Markdown) formatting. For your specific inquiry, use pairs of triple backticks, i.e.,
```
Hello
World
```
For this and other formatting directives, see either the consumer help page (for end-users), or the simple messages page (for developers) in Google's documentation.
If it's a single line, you can use it between single back quote.
`Hello World`

utf8=✓ in rails 3.1 GET forms

When I use form helper with GET action, the resulting url shows utf8=✓.
It was caused by rails adding a hidden input utf8. My question is is it possible to remove this?
Why do you want to remove that field? According to this Rails Guides article it's quite useful and helps to overcome issues with some browsers (IE, I believe).
The first input element with name utf8 enforces browsers to properly
respect your form’s character encoding and is generated for all forms
whether their actions are “GET” or “POST”.
See this answer for a nice explanation about why you might need that parameter (previously snowman character was used instead of check mark).