Is it possible to set all characters in a text object to capital regardless of input?
In your script after you have created your text object and are in edit mode for it just run these two commands.

bpy.ops.font.select_all()
bpy.ops.font.case_set(case='UPPER')


That will convert all the characters in that text object to upper case, but leave it all selected.

If you want to have your text unselected (still in edit mode) run this command after the two above

bpy.ops.font.move(type='LINE_END')


Documentation on the font operators.



Here is an example script that uses the operators above to get a string from an external text file, convert it to all upper case, and make a new text object in.  

import bpy
data = ""
with open('path/to/file.txt', 'r') as file:
    rawtext = file.read()
f.closed

bpy.ops.object.text_add(view_align=False, enter_editmode=True, location=(0.0, 0.0, 0.0), layers=(True, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False))
bpy.ops.font.delete(type='ALL')
bpy.ops.font.text_insert(text = rawtext, accent = False)
bpy.ops.font.select_all()
bpy.ops.font.case_set(case='UPPER')

bpy.ops.object.mode_set(mode='OBJECT', toggle=False)


This script gets a string from an external text file, converts it to all upper case, and makes a new text object in blender; same as the script above, however this one does not use ops which will have better performance.  

import bpy

#get letters from file
file = open('path/to/file.txt')
rawtext = file.read()
file.close()

#create new text curve and object
curve = bpy.data.curves.new("curve", 'FONT')
text = bpy.data.objects.new("text", curve)

#add uppercase letters to text curve
curve.body = rawtext.upper()

#add text object to scene
bpy.context.scene.objects.link(text)