Tuesday 17 April 2018

Rev: Online audio transcription, video captions and document translation services

Rev: Online audio transcription, video captions and document translation services

Question: What does Rev provide?
Rev provide the Online audio transcription, video captions and document translation services.


Question: What type of transcription they provide?
They provide transcription like immigration, business, legal, academic and personal needs.


Question: How much they charge?
Rev charges $1 per minute of audio. For example, a 30 minute clip costs $30.00. Timestamps and verbatim are options that cost $0.25 per minute each.


Question: How long will it take?
Audio files under 30 minutes long with good quality audio are typically delivered within 12 hours.


Question: Do they provide timestamps?
Yes, $0.25 per minute.


Question: What type of file format they accept?
We accept audio and video recordings in MP3, MP4, WMV, AIF, M4A, MOV, AVI, VOB, AMR, WMA, OGG, AAC, and WAV.


Question: What is endpoint for sandbox API?
https://api-sandbox.rev.com


Question: What is endpoint for Rev API?
https://www.rev.com


Question: What is documentation URL of API?
https://www.rev.com/api


Question: How to send order online for audio/video transcription?
Step 1
  1. Upload a source file to be used in an order via i.e. /api/v1/inputs
  2. Curl Example
curl -X POST
  https://api-sandbox.rev.com/api/v1/inputs
  -H 'authorization: AUTHORIZATION_STRING_HERE'
  -H 'cache-control: no-cache'
  -H 'content-type: application/json'
  -H 'postman-token: d6eee4bb-84ef-d54b-d15d-9ac9b3230fc2'
  -d '{
    "url": "https://useastpacificgeorama.blob.core.windows.net/useastpacifiddc/GM-qE2zq-1078-5525_720p.mp4"
}'


Response Headers
Location – URI identifying the newly uploaded media. This URI can be used to identify this media when submitting an order.


Step 2
  1. Now order online i.e. /api/v1/orders
  2. Curl Example
curl -X POST
  https://api-sandbox.rev.com/api/v1/orders
  -H 'authorization: AUTHORIZATION_STRING_HERE'
  -H 'cache-control: no-cache'
  -H 'content-type: application/json'
  -H 'postman-token: 10fa5ba8-3739-c3f2-ace9-b115f3bb6f96'
  -d '{
    "client_ref": "Georama-OvanTest",
    "transcription_options": {
        "inputs": [
            {
                "audio_length_seconds": 194,
                "uri": "urn:rev:inputmedia:U3VwbG9hZHMvMjAxOC0wNC0xMy8wMzQzOTY1MC0yMDVhLTQwMDYtYWZmMC01MjI0ZTdkNTQ2MTUvR00tcUUyenEtMTA3OC01NTI1XzcyMHAubXA0"
            }
        ],
        "verbatim": true,
        "timestamps": true
    },
    "notification": {
        "url": "http://example.com/callback/url",
        "level": "Detailed"
    }
}'

Response Headers
Location – URI identifying the newly created order. This URI can be used to request details (such as status) of the order. Only present if a 201 response code is returned.



Question: How rev will communicate to us once order is completed?
Once rev, received the request.
When they just start they will notify to us through callback function.
When they just complete they will notify to us through callback function.
All data will be sent in POST method, and have following parameters.
(
    [order_number] => TD0648810924
    [client_ref] => arunkumartest
    [status] => Complete
)



Question: How to GET order details online?
We can get the order details with API using orderId.
For Example.
curl -X GET
  https://api-sandbox.rev.com/api/v1/orders/TD0648810924
  -H 'accept: application/json'
  -H 'authorization: AUTHORIZATION_STRING_HERE'
  -H 'cache-control: no-cache'
  -H 'postman-token: aad7ead8-0b44-19b1-0f19-2b5baa4a2e6a'
Response Body
 
{
    "order_number": "TD0648810924",
    "client_ref": "OvanTest",
    "price": 4.86,
    "status": "Complete",
    "priority": "Normal",
    "non_standard_tat_guarantee": false,
    "transcription": {
        "verbatim": true,
        "timestamps": true,
        "total_length": 3,
        "total_length_seconds": 194
    },
    "comments": [
        {
            "by": "Georama I.",
            "timestamp": "2018-04-13T11:57:14.97Z"
        },
        {
            "timestamp": "2018-04-13T12:02:46.997Z",
            "text": "Order delivered"
        }
    ],
    "attachments": [
        {
            "kind": "media",
            "name": "GM-qE2zq-1078-5525_720p.mp4",
            "id": "5HYQOsWDAwAAAAAA",
            "audio_length_seconds": 194,
            "links": [
                {
                    "rel": "content",
                    "href": "https://api-sandbox.rev.com/api/v1/attachments/5HYQO2s2WDAwAAAAAA/content"
                }
            ]
        },
        {
            "kind": "transcript",
            "name": "sample_transcription.docx",
            "id": "5HYQOsqDAwAAAAAA",
            "links": [
                {
                    "rel": "content",
                    "href": "https://api-sandbox.rev.com/api/v1/attachments/5HYQO2sqDA2wAAAAAA/content",
                    "content-type": "application/vnd.openxmlformats-officedocument.wordprocessingml.document"
                }
            ]
        }
    ]
}



Question: How to get transcriptions?
curl -X GET
  https://api-sandbox.rev.com/api/v1/attachments/5HYQO2s2WDAwAAAAAA/content
  -H 'accept: application/rev-transcription'
  -H 'authorization: AUTHORIZATION_STRING_HERE'
  -H 'cache-control: no-cache'
  -H 'postman-token: 4376e40d-9e6e-1e5a-e937-6337b9e1ade2'

Response
{"speakers":[{"id":1,"name":"Adam","icon":null,"color":null,"colorCoordinates":null,"note":null},{"id":2,"name":"Mike","icon":null,"color":null,"colorCoordinates":null,"note":null}],"monologues":[{"id":1,"speaker":1,"spans":[{"type":0,"value":"This is a sample first line"}],"startTime":null},{"id":2,"speaker":2,"spans":[{"type":0,"value":"This is a sample second line"}],"startTime":null}],"segments":[],"versionNumber":0,"offsetSeconds":0,"id":50,"name":"test.txt","metadata":{}}


Friday 13 April 2018

AWS Tutorial Terminology page 3

AWS Tutorial Terminology page 3

Question: What are routing table?
A routing table is a set of rules, is used to determine where data packets will be directed over the internet protocol. Internet protocol will contain the necessary information.
Each packet contains information about its origin and destination.
When a packet is received, a network device examines the packet and matches it to the routing table for its destination.


  1. Destination: this is final destination.
  2. Next hop: The IP address to which the packet is forwarded
  3. Interface: The outgoing network interface the device should use when forwarding the packet
  4. Metric: Assigns a cost to each.
  5. Routes



Question: What is subnets in VPC?
A subnet is a range of IP addresses in your VPC.
You can launch AWS resources into a specified subnet.


Question: What is IAAS PAAS SAAS?
IaaS (Infrastructure as a Service), as the name suggests, provides you the computing infrastructure, physical or (quite often) virtual machines and other resources like virtual-machine disk image library, block and file-based storage, firewalls, load balancers, IP addresses, virtual local area networks etc.
Examples: Amazon EC2, Windows Azure, Rackspace, Google Compute Engine.

PaaS (Platform as a Service), as the name suggests, provides you computing platforms which typically includes operating system, programming language execution environment, database, web server etc.
Examples: AWS Elastic Beanstalk, Windows Azure, Heroku, Force.com, Google App Engine, Apache Stratos.

While in SaaS (Software as a Service) model you are provided with access to application software often referred to as "on-demand software". You don't have to worry about the installation, setup and running of the application. Service provider will do that for you. You just have to pay and use it through some client.
Examples: Google Apps, Microsoft Office 365.


Question: How to Pass query string to AWS lamba?
You can access Query String as below:
event['pathParameters']['param1']


You can access Header String as below:
event['requestContext']['identity']['userAgent']
event['requestContext']['identity']['sourceIP']



Question: How to Make all S3 object public?
Now go to your AWS S3 console, At the bucket level, click on Properties, Expand Permissions, then Select Add bucket policy.
Following are Generate Policy.
{
  "Id": "Policy1397632521960",
  "Statement": [
    {
      "Sid": "Stmt1397633323327",
      "Action": [
        "s3:GetObject"
      ],
      "Effect": "Allow",
      "Resource": "arn:aws:s3:::bucketnm/*",
      "Principal": {
        "AWS": [
          "*"
        ]
      }
    }
  ]
}



Question: Can't ping AwS ec2 instance. How to Fix?
Add a new EC2 security group inbound rule:
Type: Custom ICMP rule
Protocol: Echo Request
Port: N/A
Source: your choice (I would select Anywhere to be able to ping from any machine)


Question: Why to use S3?
Amazon S3 is designed for large-capacity, low-cost file storage in one specific geographical region.* The storage and bandwidth costs are quite low.

Amazon CloudFront is a Content Delivery Network (CDN) which proxies and caches web data at edge locations as close to users as possible.


Question: How to download entire S3 bucket?
Execute following command from Console.
aws s3 sync s3://mybucket .